Enhydra 5.1 API

org.enhydra.xml.xmlc.reloading
Class TomcatResourceLoader

java.lang.Object
  |
  +--org.enhydra.xml.xmlc.reloading.TomcatResourceLoader
All Implemented Interfaces:
ResourceLoader

public class TomcatResourceLoader
extends java.lang.Object
implements ResourceLoader

ResourceLoader class for the Tomcat classloader. This is not ideal, as it doesn't take into account the parent loader or chances in the classpath. This works for classloader oorg.apache.tomcat.util.NetworkClassLoader and descendent org.apache.tomcat.core/ServletClassLoader.


Constructor Summary
TomcatResourceLoader(java.lang.ClassLoader classLoader, XMLCLogger logger)
          Constructor.
 
Method Summary
 java.lang.ClassLoader createSelectiveClassLoader(java.lang.String className)
          Create a selective class loader for the specified class and its subclasses.
 java.lang.ClassLoader getClassLoader()
          Get the class loader associated with this ResourceLoader instance.
 java.net.URL[] getClassPath()
          Get the class path associate with this resource loader.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TomcatResourceLoader

public TomcatResourceLoader(java.lang.ClassLoader classLoader,
                            XMLCLogger logger)
Constructor.

See Also:
ResourceLoader
Method Detail

getClassLoader

public java.lang.ClassLoader getClassLoader()
Description copied from interface: ResourceLoader
Get the class loader associated with this ResourceLoader instance.

Specified by:
getClassLoader in interface ResourceLoader
See Also:
ResourceLoader.getClassLoader()

getClassPath

public java.net.URL[] getClassPath()
Get the class path associate with this resource loader.

Specified by:
getClassPath in interface ResourceLoader

createSelectiveClassLoader

public java.lang.ClassLoader createSelectiveClassLoader(java.lang.String className)
Create a selective class loader for the specified class and its subclasses. All other classes are delegated to the ClassLoader assocation with this ResourceLoader.

Specified by:
createSelectiveClassLoader in interface ResourceLoader

Enhydra 5.1 API