All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class sun.beanbox.SimpleClassLoader

java.lang.Object
   |
   +----java.lang.ClassLoader
           |
           +----sun.beanbox.SimpleClassLoader

public class SimpleClassLoader
extends ClassLoader

Variable Index

 o ourLoader
 o urlPrefix

Method Index

 o applyDefinitions(Vector)
Define a class from the bytecodes that were collected early...
 o createLoader(String, String)
Returns an InputStream on the resource
 o defineClassFromBytes(String, byte[])
Set some bytecodes as a definition for a class.
 o getLocalResource(String)
Return a URL to the desired resource.
 o getLocalResource(String, String)
 o getLocalResourceAsStream(String, String)
 o getResource(String)
 o getResourceAsStream(String)
 o instantiate(String, InputStreamProducer)
Interface to Beans.instantiate.
 o loadClass(String)
Load a class from this class loader.
 o loadClass(String, boolean)
This is the main method for ClassLoaders, that is being redefined
 o loadClassFromFile(String)
Helper function; load a class from a file
 o setLocalResourceSource(String, InputStreamProducer)
Assign an InputStream as the source for a given property name This value comes first after the system resources

Variables

 o urlPrefix
 public static final String urlPrefix
 o ourLoader
 public static SimpleClassLoader ourLoader

Methods

 o defineClassFromBytes
 public void defineClassFromBytes(String name,
                                  byte buf[])
Set some bytecodes as a definition for a class. Do not actually define the class until later

 o loadClassFromFile
 public Class loadClassFromFile(String fileName) throws ClassNotFoundException
Helper function; load a class from a file

 o loadClass
 public Class loadClass(String name) throws ClassNotFoundException
Load a class from this class loader.

Throws: ClassNotFoundException
if the class could not be found.
Overrides:
loadClass in class ClassLoader
 o loadClass
 protected Class loadClass(String name,
                           boolean resolve) throws ClassNotFoundException
This is the main method for ClassLoaders, that is being redefined

Throws: ClassNotFoundException
if the class could not be found.
Overrides:
loadClass in class ClassLoader
 o instantiate
 public Object instantiate(String name,
                           InputStreamProducer isp) throws ClassNotFoundException, IOException
Interface to Beans.instantiate. Name is that of the bean. The stream producer provides the serialized representation of the bean

 o setLocalResourceSource
 public void setLocalResourceSource(String name,
                                    InputStreamProducer isp)
Assign an InputStream as the source for a given property name This value comes first after the system resources

 o getResource
 public URL getResource(String name)
Overrides:
getResource in class ClassLoader
 o getResourceAsStream
 public InputStream getResourceAsStream(String name)
Overrides:
getResourceAsStream in class ClassLoader
 o getLocalResource
 public URL getLocalResource(String name)
Return a URL to the desired resource.

 o createLoader
 public static SimpleClassLoader createLoader(String cookie,
                                              String dir)
Returns an InputStream on the resource

 o getLocalResource
 public static Object getLocalResource(String cookie,
                                       String name)
 o getLocalResourceAsStream
 public static InputStream getLocalResourceAsStream(String cookie,
                                                    String name)
 o applyDefinitions
 public synchronized boolean applyDefinitions(Vector classList)
Define a class from the bytecodes that were collected early... Will return false if there were problems applying the definitions This is only invoked if we are defining classes up front. Code will be removed if we don't discover any problems in testing.


All Packages  Class Hierarchy  This Package  Previous  Next  Index