Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.caucho.util
Class DirectoryClassLoader

    java.lang.Object
      |
      +--java.lang.ClassLoader
            |
            +--java.security.SecureClassLoader
                  |
                  +--com.caucho.util.DynamicClassLoader
                        |
                        +--com.caucho.util.DirectoryClassLoader

public class DirectoryClassLoader
extends DynamicClassLoader

Class loader which checks for changes in class files and automatically picks up new jars.

Inner classes inherited from class com.caucho.util.DynamicClassLoader
`DynamicClassLoader.Entry`

Fields inherited from class com.caucho.util.DynamicClassLoader
`top`

Constructor Summary
`protected` | `DirectoryClassLoader(java.lang.ClassLoader parent)`

Method Summary
`static DirectoryClassLoader` | `create(java.lang.ClassLoader parent, Path dir)` Create a new class loader
`protected java.lang.String` | `getClassPath(java.lang.String head)` Fill data for the class path.
`protected Path` | `getCodePath()`
`protected Path` | `getPath(java.lang.String pathName)` Find a given path somewhere in the classpath
`protected boolean` | `isModifiedInt()` True if any of the loaded classes have been modified.

Methods inherited from class com.caucho.util.DynamicClassLoader
`addCodeBasePath, addListener, addParentPriorityPackage, addPermission, addPermission, addPermissions, destroy, findClass, findLibrary, getAttribute, getClassEntry, getClassPath, getLevelAttribute, getParentLoader, getPermissions, getPermissions, getResource, getResourceAsStream, getSourcePath, getSourcePath, getTop, isModified, loadClass, loadClass, makeAll, makeAllInt, setAttribute, setNext, setServletHack, unload`

Methods inherited from class java.security.SecureClassLoader
`defineClass`

Methods inherited from class java.lang.ClassLoader
`defineClass, defineClass, defineClass, definePackage, findLoadedClass, findResource, findResources, findSystemClass, getPackage, getPackages, getParent, getResources, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, loadClass, resolveClass, setSigners`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### DirectoryClassLoader

    protected DirectoryClassLoader(java.lang.ClassLoader parent)

Method Detail

### create

    public static DirectoryClassLoader create(java.lang.ClassLoader parent,
                                              Path dir)

  Create a new class loader
  Parameters:
    `parent` - parent class loader
    `dir` - directories which can handle dynamic jar addition

### isModifiedInt

    protected boolean isModifiedInt()

  True if any of the loaded classes have been modified. If true, the caller should drop the classpath and create a new one.
  Overrides:
    `isModifiedInt` in class `DynamicClassLoader`

### getClassPath

    protected java.lang.String getClassPath(java.lang.String head)

  Fill data for the class path. fillClassPath() will add all .jar and .zip files in the directory list.
  Overrides:
    `getClassPath` in class `DynamicClassLoader`

### getPath

    protected Path getPath(java.lang.String pathName)

  Find a given path somewhere in the classpath
  Overrides:
    `getPath` in class `DynamicClassLoader`
  Parameters:
    `pathName` - the relative resourceName
  Returns:
    the matching path or null

### getCodePath

    protected Path getCodePath()

  Overrides:
    `getCodePath` in class `DynamicClassLoader`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD