Overview | Package | Class | Tree | Deprecated | Index | Help
| Openfire 3.7.1 Javadoc
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jivesoftware.openfire.container
Class PluginClassLoader

    java.lang.Object
      java.lang.ClassLoader
          java.security.SecureClassLoader
              java.net.URLClassLoader
                  org.jivesoftware.openfire.container.PluginClassLoader

    public class PluginClassLoader

extends URLClassLoader

ClassLoader for plugins. It searches the plugin directory for classes and JAR files, then constructs a class loader for the resources found. Resources are loaded as follows:

- Any JAR files in the `lib` will be added to the classpath.
- Any files in the classes directory will be added to the classpath.

Author:
  Derek DeMoro

Constructor Summary
`PluginClassLoader()`

Method Summary
`void` | `addDirectory(File directory, boolean developmentMode)` Adds a directory to the class loader.
`void` | `addURLFile(URL file)`

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

### PluginClassLoader

    public PluginClassLoader()

Method Detail

### addDirectory

    public void addDirectory(File directory,
                             boolean developmentMode)

  Adds a directory to the class loader.

  Parameters:
    `directory` - the directory.
    `developmentMode` - true if the plugin is running in development mode. This resolves classloader conflicts between the deployed plugin and development classes.

### addURLFile

    public void addURLFile(URL file)

Overview | Package | Class | Tree | Deprecated | Index | Help
| Openfire 3.7.1 Javadoc
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2003-2008 Jive Software.