org.helma.tools.launcher
Class HelmaClassLoader

java.lang.Object
  extended by java.lang.ClassLoader
      extended by java.security.SecureClassLoader
          extended by java.net.URLClassLoader
              extended by org.helma.tools.launcher.HelmaClassLoader

public class HelmaClassLoader
extends java.net.URLClassLoader

Classloader used for application class loading. The main purpose of this class is to make protected addURL visible to the org.helma.javascript package. FIXME: class lookups are cached, so adding a jar file after a class has already been looked up won't make the classes available. Maybe we should go with disposable classloaders and create a new one for each added URL.


Constructor Summary
HelmaClassLoader()
           
HelmaClassLoader(java.io.File home, java.lang.String[] classpath)
           
HelmaClassLoader(java.net.URL[] urls)
           
HelmaClassLoader(java.net.URL[] urls, java.lang.ClassLoader parent)
           
 
Method Summary
protected  void addClasspathWildcard(java.io.File dir, boolean recursive)
           
protected  void addURL(java.net.URL url)
           
protected  java.io.File getAbsoluteFile(java.io.File home, java.lang.String path)
           
 
Methods inherited from class java.net.URLClassLoader
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

HelmaClassLoader

public HelmaClassLoader()

HelmaClassLoader

public HelmaClassLoader(java.net.URL[] urls)

HelmaClassLoader

public HelmaClassLoader(java.io.File home,
                        java.lang.String[] classpath)
                 throws java.net.MalformedURLException
Throws:
java.net.MalformedURLException

HelmaClassLoader

public HelmaClassLoader(java.net.URL[] urls,
                        java.lang.ClassLoader parent)
Method Detail

addURL

protected void addURL(java.net.URL url)
Overrides:
addURL in class java.net.URLClassLoader

addClasspathWildcard

protected void addClasspathWildcard(java.io.File dir,
                                    boolean recursive)
                             throws java.net.MalformedURLException
Throws:
java.net.MalformedURLException

getAbsoluteFile

protected java.io.File getAbsoluteFile(java.io.File home,
                                       java.lang.String path)