public class ManifoldCFResourceLoader
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
_rcsid |
protected java.lang.ClassLoader |
classLoader
The class loader we're caching
|
protected java.util.ArrayList |
currentClasspath
The current 'classpath' - a list of File objects
|
protected java.lang.ClassLoader |
parent
The parent class loader
|
| Constructor and Description |
|---|
ManifoldCFResourceLoader(java.lang.ClassLoader parent)
Construct a resource manager.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
addDirsToClassPath(java.io.File[] baseList,
java.io.FileFilter[] filterList)
Add fully-resolved directories (with filters) to the current class path.
|
void |
addToClassPath(java.io.File file)
Add to the class-search path.
|
void |
addToClassPath(java.io.File dir,
java.io.FileFilter filter)
Add to the class-search path.
|
void |
clearClassPath()
Clear the class-search path.
|
java.lang.Class |
findClass(java.lang.String cname)
Get the specified class using the proper classloader.
|
java.lang.ClassLoader |
getClassLoader()
Get the class loader representing this resource loader.
|
void |
setClassPath(java.util.ArrayList libdirList)
Set the classpath to a given list of libdirs.
|
public static final java.lang.String _rcsid
protected java.lang.ClassLoader parent
protected java.lang.ClassLoader classLoader
protected java.util.ArrayList currentClasspath
public ManifoldCFResourceLoader(java.lang.ClassLoader parent)
throws ManifoldCFException
parent - is the parent class loader.ManifoldCFExceptionpublic void setClassPath(java.util.ArrayList libdirList)
throws ManifoldCFException
libdirList - is an arraylist of File objects, each representing a directory.ManifoldCFExceptionpublic void clearClassPath()
public void addToClassPath(java.io.File file)
throws ManifoldCFException
file - is the jar or class root.ManifoldCFExceptionpublic void addToClassPath(java.io.File dir,
java.io.FileFilter filter)
throws ManifoldCFException
dir - is the directory to add.filter - is the file filter to use on that directory.ManifoldCFExceptionpublic java.lang.ClassLoader getClassLoader()
throws ManifoldCFException
ManifoldCFExceptionpublic java.lang.Class findClass(java.lang.String cname)
throws java.lang.ClassNotFoundException,
ManifoldCFException
cname - is the fully-qualified class name.java.lang.ClassNotFoundExceptionManifoldCFExceptionprotected void addDirsToClassPath(java.io.File[] baseList,
java.io.FileFilter[] filterList)
throws ManifoldCFException
baseList - is the list of library directories.filterList - is the corresponding list of filters.ManifoldCFException