org.jboss.remoting.loading
Class ClassByteClassLoader

java.lang.Object
  extended byjava.lang.ClassLoader
      extended byorg.jboss.remoting.loading.ClassByteClassLoader

public class ClassByteClassLoader
extends java.lang.ClassLoader

ClassByteClassLoader is a classloader that will allow dynamic adding of classes from a remote machine to be added and visible locally.


Constructor Summary
ClassByteClassLoader()
           
ClassByteClassLoader(java.lang.ClassLoader parent)
           
 
Method Summary
 java.lang.Class addClass(ClassBytes (src)  classBytes)
           
 void destroy()
          Will disconnect loader client if is present.
protected  void finalize()
           
protected  java.lang.Class findClass(java.lang.String name)
          Finds the specified class.
 java.io.InputStream getResourceAsStream(java.lang.String name)
           
 java.lang.Class loadClass(java.lang.String className, ClassBytes (src) [] bytes)
           
 void setClientInvoker(Client (src)  loaderClient)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.ClassLoader
clearAssertionStatus, defineClass, defineClass, defineClass, definePackage, findLibrary, findLoadedClass, findResource, findResources, findSystemClass, getPackage, getPackages, getParent, getResource, getResources, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, loadClass, loadClass, resolveClass, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSigners
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ClassByteClassLoader

public ClassByteClassLoader()

ClassByteClassLoader

public ClassByteClassLoader(java.lang.ClassLoader parent)
Method Detail

setClientInvoker

public void setClientInvoker(Client (src)  loaderClient)

destroy

public void destroy()
Will disconnect loader client if is present.


toString

public java.lang.String toString()

finalize

protected void finalize()
                 throws java.lang.Throwable
Throws:
java.lang.Throwable

loadClass

public java.lang.Class loadClass(java.lang.String className,
                                 ClassBytes (src) [] bytes)
                          throws java.lang.ClassNotFoundException,
                                 java.io.IOException
Throws:
java.lang.ClassNotFoundException
java.io.IOException

getResourceAsStream

public java.io.InputStream getResourceAsStream(java.lang.String name)

addClass

public java.lang.Class addClass(ClassBytes (src)  classBytes)
                         throws java.io.IOException
Throws:
java.io.IOException

findClass

protected java.lang.Class findClass(java.lang.String name)
                             throws java.lang.ClassNotFoundException
Finds the specified class. This method should be overridden by class loader implementations that follow the new delegation model for loading classes, and will be called by the loadClass method after checking the parent class loader for the requested class. The default implementation throws ClassNotFoundException.

Parameters:
name - the name of the class
Returns:
the resulting Class object
Throws:
java.lang.ClassNotFoundException - if the class could not be found
Since:
1.2