|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.ungoverned.moduleloader.search.SelfContainedSearchPolicy
This class implements a ModuleLoader search policy that assumes that all modules are self-contained. In other words, when loading a class or resource for a particular module, only that particular module's resource sources are search. No classes or resources are shared among modules.
SearchPolicy
,
Module
,
ModuleClassLoader
,
ModuleManager
Constructor Summary | |
SelfContainedSearchPolicy()
|
Method Summary | |
java.lang.Class |
findClass(Module module,
java.lang.String name)
Simply returns null which forces the module class loader to only search the target module's resource sources for the specified class. |
java.net.URL |
findResource(Module module,
java.lang.String name)
Simply returns null which forces the module class loader to only search the target module's resource sources for the specified resource. |
void |
setModuleManager(ModuleManager mgr)
This method is part of the SearchPolicy interface. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public SelfContainedSearchPolicy()
Method Detail |
public void setModuleManager(ModuleManager mgr) throws java.lang.IllegalStateException
setModuleManager
in interface SearchPolicy
mgr
- the module manager associated with this search policy.
java.lang.IllegalStateException
- if the method is called
more than once.public java.lang.Class findClass(Module module, java.lang.String name)
findClass
in interface SearchPolicy
module
- the target module that is loading the class.name
- the name of the class being loaded.
public java.net.URL findResource(Module module, java.lang.String name)
findResource
in interface SearchPolicy
module
- the target module that is loading the class.name
- the name of the resource being loaded.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |