|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object info.magnolia.module.ModuleManagerImpl
@Singleton public class ModuleManagerImpl
TODO : factor out into simpler units.
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface info.magnolia.module.ModuleManager |
---|
ModuleManager.Factory, ModuleManager.ModuleAndDeltas, ModuleManager.ModuleManagementState |
Constructor Summary | |
---|---|
protected |
ModuleManagerImpl()
Deprecated. since 4.5 - use IoC - temporarily kept for tests ? |
protected |
ModuleManagerImpl(InstallContextImpl installContext,
ModuleDefinitionReader moduleDefinitionReader)
Deprecated. since 4.5 - use IoC - temporarily kept for tests ? |
|
ModuleManagerImpl(InstallContextImpl installContext,
ModuleDefinitionReader moduleDefinitionReader,
ModuleRegistry moduleRegistry,
DependencyChecker dependencyChecker,
Node2BeanProcessor nodeToBean)
|
Method Summary | |
---|---|
protected void |
applyDeltas(ModuleDefinition moduleDef,
List<Delta> deltas,
InstallContextImpl ctx)
Applies to given deltas for the given module. |
void |
checkForInstallOrUpdates()
In addition to checking for install or updates, this method also loads repositories when there are no pending install or update tasks. |
protected void |
executeStartupTasks()
Process startup tasks. |
InstallContext |
getInstallContext()
|
protected Map<String,Object> |
getModuleInstanceProperties(ModuleDefinition moduleDefinition)
Builds a map of properties to be set on the module instance, the properties are "moduleDefinition", "name", "moduleNode" and "configNode". |
ModuleManager.ModuleManagementState |
getStatus()
Returns the status as discovered by checkForInstallOrUpdates(). |
ModuleManagerUI |
getUI()
|
protected void |
installOrUpdateModule(ModuleManager.ModuleAndDeltas moduleAndDeltas,
InstallContextImpl ctx)
|
List<ModuleDefinition> |
loadDefinitions()
Loads modules definitions, validates dependencies and sorts modules by dependencies. |
protected ModuleVersionHandler |
newVersionHandler(ModuleDefinition module)
|
void |
performInstallOrUpdate()
|
protected void |
populateModuleInstance(Object moduleInstance,
Map<String,Object> moduleProperties)
|
protected void |
startModule(Object moduleInstance,
ModuleDefinition moduleDefinition,
ModuleLifecycleContextImpl lifecycleContext)
|
void |
startModules()
|
protected void |
stopModule(Object moduleInstance,
ModuleDefinition moduleDefinition,
ModuleLifecycleContextImpl lifecycleContext)
|
void |
stopModules()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
@Deprecated protected ModuleManagerImpl()
@Deprecated protected ModuleManagerImpl(InstallContextImpl installContext, ModuleDefinitionReader moduleDefinitionReader)
@Inject public ModuleManagerImpl(InstallContextImpl installContext, ModuleDefinitionReader moduleDefinitionReader, ModuleRegistry moduleRegistry, DependencyChecker dependencyChecker, Node2BeanProcessor nodeToBean)
Method Detail |
---|
public List<ModuleDefinition> loadDefinitions() throws ModuleManagementException
ModuleManager
loadDefinitions
in interface ModuleManager
ModuleManagementException
public void checkForInstallOrUpdates()
checkForInstallOrUpdates
in interface ModuleManager
ModuleManager.checkForInstallOrUpdates()
public ModuleManager.ModuleManagementState getStatus()
ModuleManager
getStatus
in interface ModuleManager
public ModuleManagerUI getUI()
getUI
in interface ModuleManager
protected ModuleVersionHandler newVersionHandler(ModuleDefinition module)
public void performInstallOrUpdate()
performInstallOrUpdate
in interface ModuleManager
public InstallContext getInstallContext()
getInstallContext
in interface ModuleManager
public void startModules()
startModules
in interface ModuleManager
protected void executeStartupTasks()
ModuleDefinition.getStartupTasks()
are always executed and
do not require manual intervention.
protected void startModule(Object moduleInstance, ModuleDefinition moduleDefinition, ModuleLifecycleContextImpl lifecycleContext)
protected void stopModule(Object moduleInstance, ModuleDefinition moduleDefinition, ModuleLifecycleContextImpl lifecycleContext)
protected Map<String,Object> getModuleInstanceProperties(ModuleDefinition moduleDefinition)
protected void populateModuleInstance(Object moduleInstance, Map<String,Object> moduleProperties)
public void stopModules()
stopModules
in interface ModuleManager
protected void installOrUpdateModule(ModuleManager.ModuleAndDeltas moduleAndDeltas, InstallContextImpl ctx)
protected void applyDeltas(ModuleDefinition moduleDef, List<Delta> deltas, InstallContextImpl ctx)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |