public class DefaultModuleActivator extends Object implements ModuleActivator
public static void moduleActivate( Module thisModule ); public static void moduleDeactivate( Module thisModule );
Modifier and Type | Field and Description |
---|---|
static String |
ACTIVATION_METHOD_NAME
Name of the activation method in the ModuleInit class.
|
static String |
DEACTIVATION_METHOD_NAME
Name of the deactivation method in the ModuleInit class.
|
protected Module |
theModule
The Module that this ModuleActivator can activate.
|
Constructor and Description |
---|
DefaultModuleActivator(Module mod)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
Object |
activate()
Activate a Module.
|
void |
deactivate()
Deactivate a Module.
|
ModuleActivator |
dependentModuleActivator(Module dependentModule)
Obtain a ModuleActivator that is responsible for activating a dependent Module.
|
Module |
getModule()
Obtain the Module that this ModuleActivator can activate.
|
protected final Module theModule
public static final String ACTIVATION_METHOD_NAME
public static final String DEACTIVATION_METHOD_NAME
public DefaultModuleActivator(Module mod)
mod
- the Module to activatepublic Module getModule()
getModule
in interface ModuleActivator
public Object activate() throws ModuleActivationException
activate
in interface ModuleActivator
ModuleActivationException
- throws if the Module could not be activatedpublic void deactivate() throws ModuleDeactivationException
deactivate
in interface ModuleActivator
ModuleDeactivationException
- throws if the Module could not be deactivatedpublic ModuleActivator dependentModuleActivator(Module dependentModule)
dependentModuleActivator
in interface ModuleActivator
dependentModule
- the dependent Module to activateCopyright © 2018. All rights reserved.