public class ModuleController
extends java.lang.Object
AbstractModule
s.Modifier and Type | Field and Description |
---|---|
static java.util.HashMap<java.lang.String,GenericModule> |
genericModules
HashMap of all available
GenericModule s. |
Constructor and Description |
---|
ModuleController()
Constructor will initialize the set of available
GenericModule s. |
Modifier and Type | Method and Description |
---|---|
static GenericModule |
getGenericModule(java.lang.String moduleName)
Returns a
GenericModule with a specific name. |
static java.util.Collection<GenericModule> |
getGenericModuleSet()
Returns a collection of all available
GenericModule s. |
static AbstractModule |
getModuleInstance(java.lang.Class<? extends AbstractModule> moduleClass)
Creates an
AbstractModule instance from a class. |
static AbstractModule |
loadModule(java.lang.String moduleName)
Returns a newly created
AbstractModule instance. |
public static java.util.HashMap<java.lang.String,GenericModule> genericModules
GenericModule
s. The hash String is the
module namepublic ModuleController()
GenericModule
s.public static AbstractModule getModuleInstance(java.lang.Class<? extends AbstractModule> moduleClass)
AbstractModule
instance from a class.moduleClass
- public static AbstractModule loadModule(java.lang.String moduleName)
AbstractModule
instance. Looks up at the
set of GenericModule
s to find the right class to be instantiated,
based on the module name.moduleName
- public static GenericModule getGenericModule(java.lang.String moduleName)
GenericModule
with a specific name.moduleName
- the name of the GenericModulepublic static java.util.Collection<GenericModule> getGenericModuleSet()
GenericModule
s.