Save This Page
Home » jboss-5.0.0.CR1-src » org.jboss.mx » loading » [javadoc | source]
org.jboss.mx.loading
public class: HeirarchicalLoaderRepository4 [javadoc | source]
java.lang.Object
   org.jboss.mx.loading.LoaderRepository
      org.jboss.mx.loading.UnifiedLoaderRepository4
         org.jboss.mx.loading.HeirarchicalLoaderRepository4

All Implemented Interfaces:
    NotificationBroadcaster, UnifiedLoaderRepository4MBean, ServerConstants, ClassLoaderRepository

A simple extension of UnifiedLoaderRepository3 that adds the notion of a parent UnifiedLoaderRepository. Classes and resources are loaded from child first and then the parent depending on the java2ParentDelegaton flag.
Nested Class Summary:
static class  HeirarchicalLoaderRepository4.NoParentClassLoader  A ClassLoader override that prevents a child class loader from looking beyond its URLs for classes. 
static class  HeirarchicalLoaderRepository4.UClWrapper   
Fields inherited from org.jboss.mx.loading.LoaderRepository:
loaders,  instance,  translator
Constructor:
 public HeirarchicalLoaderRepository4(MBeanServer server) throws InstanceNotFoundException, ReflectionException, AttributeNotFoundException, MBeanException 
 public HeirarchicalLoaderRepository4(UnifiedLoaderRepository4 parentRepository) 
 public HeirarchicalLoaderRepository4(MBeanServer server,
    ObjectName parentName) throws InstanceNotFoundException, ReflectionException, AttributeNotFoundException, MBeanException 
Method from org.jboss.mx.loading.HeirarchicalLoaderRepository4 Summary:
getClassLoader,   getResource,   getResources,   getURLs,   getUseParentFirst,   internalGetClassLoader,   internalGetParentClassLoader,   loadClass,   loadClassFromCache,   newClassLoader,   newClassLoader,   setUseParentFirst
Methods from org.jboss.mx.loading.UnifiedLoaderRepository4:
addClassLoader,   addClassLoaderURL,   addNotificationListener,   cacheLoadedClass,   displayClassInfo,   flush,   getCacheSize,   getClassIndexSize,   getClassLoader,   getClassLoaders,   getClassLoaders,   getClassLoadersSize,   getClassNamesMap,   getClasses,   getInstance,   getLoaderToClassesMap,   getNotificationInfo,   getResource,   getResources,   getURLs,   loadClass,   loadClass,   loadClassFromCache,   loadClassFromClassLoader,   loadClassWithout,   newClassLoader,   newClassLoader,   registerClassLoader,   removeClassLoader,   removeNotificationListener
Methods from org.jboss.mx.loading.LoaderRepository:
addClassLoader,   addClassLoaderURL,   cacheLoadedClass,   clear,   compare,   getCachedClass,   getLoaders,   getNativeClassForName,   getResource,   getResources,   getTranslator,   getURLs,   loadClass,   loadClass,   loadClassBefore,   loadClassWithout,   newClassLoader,   newClassLoader,   removeClassLoader,   reverseCompare,   setTranslator
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.jboss.mx.loading.HeirarchicalLoaderRepository4 Detail:
 public UnifiedClassLoader4 getClassLoader(String name) 
    Called by LoadMgr to obtain all class loaders. This returns a set of PkgClassLoader with the HeirarchicalLoaderRepository3 ordered ahead of the parent repository pkg class loaders
 public URL getResource(String name,
    ClassLoader scl) 
    Find a resource from this repository. This first looks to this repository and then the parent repository.
 public  void getResources(String name,
    ClassLoader cl,
    List urls) 
    Find all resource URLs for the given name. This is entails an exhuastive search of this and the parent repository and is an expensive operation.
 public URL[] getURLs() 
    Obtain a listing of the URLs for all UnifiedClassLoaders associated with the repository
 public boolean getUseParentFirst() 
    Get the use parent first flag. This indicates whether the parent repository is consulted first for resource and class loading or if the HeirchicalLoaderRepository is consulted first.
 UnifiedClassLoader4 internalGetClassLoader(String name) 
 UnifiedClassLoader4 internalGetParentClassLoader() 
 public Class loadClass(String name,
    boolean resolve,
    ClassLoader scl) throws ClassNotFoundException 
    Load a class using the repository class loaders.
 public Class loadClassFromCache(String name) 
    Called by LoadMgr to locate a previously loaded class. This looks first to this repository and then the parent repository.
 public UnifiedClassLoader newClassLoader(URL url,
    boolean addToRepository) throws Exception 
 public UnifiedClassLoader newClassLoader(URL url,
    URL origURL,
    boolean addToRepository) throws Exception 
 public  void setUseParentFirst(boolean flag) 
    Set the use parent first flag. This indicates whether the parent repository is consulted first for resource and class loading or if the HeirchicalLoaderRepository is consulted first.