|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sun.enterprise.module.common_impl.AbstractModulesRegistryImpl
com.sun.enterprise.module.impl.ModulesRegistryImpl
public class ModulesRegistryImpl
| Field Summary |
|---|
| Fields inherited from class com.sun.enterprise.module.common_impl.AbstractModulesRegistryImpl |
|---|
modules, parent, providers, repositories |
| Constructor Summary | |
|---|---|
ModulesRegistryImpl(ModulesRegistry parent)
|
|
| Method Summary | |
|---|---|
ModulesRegistry |
createChild()
Creates a new child ModulesRegistryImpl in this ModulesRegistryImpl. |
void |
detachAll()
Detaches all the modules from this registry. |
Module |
find(java.lang.Class clazz)
Finds the Module that owns the given class. |
java.util.List<ModuleLifecycleListener> |
getLifecycleListeners()
|
java.lang.ClassLoader |
getModulesClassLoader(java.lang.ClassLoader parent,
java.util.Collection<ModuleDefinition> defs)
Returns a ClassLoader capable of loading classes from a set of modules identified by their module definition |
java.lang.ClassLoader |
getModulesClassLoader(java.lang.ClassLoader parent,
java.util.Collection<ModuleDefinition> defs,
java.net.URL[] urls)
Returns a ClassLoader capable of loading classes from a set of modules identified by their module definition and also load new urls. |
java.lang.ClassLoader |
getParentClassLoader()
Returns the parent class loader parenting the class loaders created by modules associated with this registry. |
ModuleImpl |
getProvidingModule(java.lang.String providerClassName)
Gets the Module that provides the provider of the given name. |
protected Module |
newModule(ModuleDefinition moduleDef)
Factory method for creating new instances of Module. |
protected java.util.List<ActiveDescriptor> |
parseInhabitants(Module module,
java.lang.String name,
ServiceLocator serviceLocator)
|
void |
register(ModuleLifecycleListener listener)
Add a ModuleLifecycleListener to this registry. |
void |
setParentClassLoader(java.lang.ClassLoader parent)
Sets the classloader parenting the class loaders created by the modules associated with this registry. |
void |
shutdown()
Shuts down this module's registry, apply housekeeping tasks |
void |
unregister(ModuleLifecycleListener listener)
Removes an ModuleLifecycleListener from this registry. |
| Methods inherited from class com.sun.enterprise.module.common_impl.AbstractModulesRegistryImpl |
|---|
add, add, add, addRepository, addRepository, changed, createInhabitantsParser, createServiceLocator, createServiceLocator, createServiceLocator, dumpState, getModules, getModules, getModulesProvider, getProvidersClass, getRepository, getRunningServices, initializeServiceLocator, loadFromRepository, makeModuleFor, makeModuleFor, makeModuleFor, newServiceLocator, newServiceLocator, populateConfig, populateServiceLocator, print, registerRunningService, remove, removeRepository, unregisterRunningService |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ModulesRegistryImpl(ModulesRegistry parent)
| Method Detail |
|---|
public ModulesRegistry createChild()
ModulesRegistryImpl in this ModulesRegistryImpl.
protected Module newModule(ModuleDefinition moduleDef)
AbstractModulesRegistryImpl
newModule in class AbstractModulesRegistryImplmoduleDef - module definition of the new module to be created
protected java.util.List<ActiveDescriptor> parseInhabitants(Module module,
java.lang.String name,
ServiceLocator serviceLocator)
throws java.io.IOException
parseInhabitants in class AbstractModulesRegistryImpljava.io.IOExceptionpublic ModuleImpl getProvidingModule(java.lang.String providerClassName)
ModulesRegistryModule that provides the provider of the given name.
getProvidingModule in interface ModulesRegistrygetProvidingModule in class AbstractModulesRegistryImplpublic void setParentClassLoader(java.lang.ClassLoader parent)
parent - parent class loaderpublic java.lang.ClassLoader getParentClassLoader()
public java.lang.ClassLoader getModulesClassLoader(java.lang.ClassLoader parent,
java.util.Collection<ModuleDefinition> defs,
java.net.URL[] urls)
throws ResolveError
parent - the parent class loader for the returned class loader instancedefs - module definitions for all modules this classloader should be
capable of loadingurls - urls to be added to the module classloader
ResolveError - if one of the provided module
definition cannot be resolved
public java.lang.ClassLoader getModulesClassLoader(java.lang.ClassLoader parent,
java.util.Collection<ModuleDefinition> defs)
throws ResolveError
parent - the parent class loader for the returned class loader instancedefs - module definitions for all modules this classloader should be
capable of loading classes from
ResolveError - if one of the provided module
definition cannot be resolvedpublic Module find(java.lang.Class clazz)
ModulesRegistryModule that owns the given class.
public void register(ModuleLifecycleListener listener)
ModuleLifecycleListener to this registry. The listener
will be notified for each module startup and shutdown.
listener - the listener implementationpublic void unregister(ModuleLifecycleListener listener)
ModuleLifecycleListener from this registry.
Notification of module startup and shutdown will not be emitted to this
listener any longer.
listener - the listener to unregisterpublic java.util.List<ModuleLifecycleListener> getLifecycleListeners()
public void detachAll()
public void shutdown()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||