|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.lang.ClassLoader java.security.SecureClassLoader java.net.URLClassLoader org.jivesoftware.spark.plugin.PluginClassLoader
public class PluginClassLoader
A simple classloader to extend the classpath to include all jars in a lib directory.
The new classpath includes all *.jar files.
Constructor Summary | |
---|---|
PluginClassLoader(java.lang.ClassLoader parent,
java.io.File libDir)
Constructs the classloader. |
Method Summary | |
---|---|
void |
addPlugin(java.io.File pluginDir)
Adds all archives in a plugin to the classpath. |
Methods inherited from class java.net.URLClassLoader |
---|
addURL, definePackage, findClass, findResource, findResources, getPermissions, getURLs, newInstance, newInstance |
Methods inherited from class java.security.SecureClassLoader |
---|
defineClass, defineClass |
Methods inherited from class java.lang.ClassLoader |
---|
clearAssertionStatus, defineClass, defineClass, defineClass, defineClass, definePackage, findLibrary, findLoadedClass, findSystemClass, getPackage, getPackages, getParent, getResource, getResourceAsStream, getResources, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, loadClass, loadClass, resolveClass, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSigners |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PluginClassLoader(java.lang.ClassLoader parent, java.io.File libDir) throws java.net.MalformedURLException
parent
- the parent class loader (or null for none).libDir
- the directory to load jar files from.
java.net.MalformedURLException
- if the libDir path is not valid.Method Detail |
---|
public void addPlugin(java.io.File pluginDir) throws java.net.MalformedURLException
pluginDir
- the directory of the plugin.
java.net.MalformedURLException
- the exception thrown if URL is not valid.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |