com.sun.jaw.reference.common
Class LoaderRepository
java.lang.Object
|
+--com.sun.jaw.reference.common.LoaderRepository
- public class LoaderRepository
- extends java.lang.Object
- implements java.io.Serializable
The class is a repository for all the class loaders that can run inside
a JDMK agent or it associated clients.
- See Also:
- Serialized Form
Method Summary |
static void |
addClassLoader(java.lang.ClassLoader aloader)
Add a class loader in the list of class loaders. |
static java.lang.Class |
loadClass(java.lang.String className)
Go thru the list of class loaders and try to load the requested class. |
static java.lang.Class |
loadClassWithout(java.lang.ClassLoader aloader,
java.lang.String className)
Go thru the list of class loaders but exclude the given class loader, then try to load
the requested class. |
static void |
removeClassLoader(java.lang.ClassLoader aloader)
Remove a class loader from the list of class loaders. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
LoaderRepository
public LoaderRepository()
addClassLoader
public static void addClassLoader(java.lang.ClassLoader aloader)
- Add a class loader in the list of class loaders.
A same class loader can be added several times.
removeClassLoader
public static void removeClassLoader(java.lang.ClassLoader aloader)
- Remove a class loader from the list of class loaders.
loadClass
public static java.lang.Class loadClass(java.lang.String className)
throws java.lang.ClassNotFoundException
- Go thru the list of class loaders and try to load the requested class.
The method will stop as soon as the class is found. If the class
is not found the method will throw a
ClassNotFoundException
exception.
- Throws:
- java.lang.ClassNotFoundException - The specified class could not be found.
loadClassWithout
public static java.lang.Class loadClassWithout(java.lang.ClassLoader aloader,
java.lang.String className)
throws java.lang.ClassNotFoundException
- Go thru the list of class loaders but exclude the given class loader, then try to load
the requested class.
The method will stop as soon as the class is found. If the class
is not found the method will throw a
ClassNotFoundException
exception.
- Throws:
- java.lang.ClassNotFoundException - The specified class could not be found.