org.objectweb.medor.optim.lib
Class DirsCompileClassLoader

java.lang.Object
  extended byjava.lang.ClassLoader
      extended byorg.objectweb.medor.optim.lib.DirsCompileClassLoader

public class DirsCompileClassLoader
extends java.lang.ClassLoader

A class loader that always checks a list of special directories on the hard disk to load classes or Java source files when compilation if needed.

The principal method loadClass(name,resolve) is coded so that name represents a Class file name or a Java source file. In the second case, the Java source file is compiled and loaded. The class loaded are used in the current application, so loading the class referenced by these classes is delegated to the class system loader if they are already loaded.


Constructor Summary
DirsCompileClassLoader(java.util.HashSet classpaths)
           
 
Method Summary
 java.lang.Class loadClass(java.lang.String name, boolean resolve)
           
 
Methods inherited from class java.lang.ClassLoader
clearAssertionStatus, defineClass, defineClass, defineClass, definePackage, findClass, findLibrary, findLoadedClass, findResource, findResources, findSystemClass, getPackage, getPackages, getParent, getResource, getResourceAsStream, getResources, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, 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

DirsCompileClassLoader

public DirsCompileClassLoader(java.util.HashSet classpaths)
Method Detail

loadClass

public java.lang.Class loadClass(java.lang.String name,
                                 boolean resolve)
                          throws java.lang.ClassNotFoundException
Throws:
java.lang.ClassNotFoundException