dermi
Class BusClassLoader

java.lang.Object
  extended by java.lang.ClassLoader
      extended by dermi.BusClassLoader
All Implemented Interfaces:
RemoteEventListener

public class BusClassLoader
extends java.lang.ClassLoader
implements RemoteEventListener

This is a custom class loader that makes a request to the remote object for the stub class when this is not found on the local machine. The remote object then sends the stub class using the event service and the BusClassLoader loads it in the custom virtual machine enabling highly dynamic remote applications.
The difference between Java

Author:
Carles Pairot , Pedro Garcia

Constructor Summary
BusClassLoader(java.util.Properties env)
          Class constructor
 
Method Summary
 void close()
          This method should be used before closing any instance of this class
 void eventArrived(java.util.Hashtable evt)
          This method is called whenever an event is received
 java.lang.Class loadClass(java.lang.String name, boolean resolve)
          Method for remote class to load the specifed class
 
Methods inherited from class java.lang.ClassLoader
clearAssertionStatus, defineClass, 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

BusClassLoader

public BusClassLoader(java.util.Properties env)
Class constructor

Parameters:
env - Properties Environment properties
Method Detail

eventArrived

public void eventArrived(java.util.Hashtable evt)
This method is called whenever an event is received

Specified by:
eventArrived in interface RemoteEventListener
Parameters:
evt - Hashtable Event data

close

public void close()
This method should be used before closing any instance of this class


loadClass

public java.lang.Class loadClass(java.lang.String name,
                                 boolean resolve)
                          throws java.lang.ClassNotFoundException
Method for remote class to load the specifed class

Overrides:
loadClass in class java.lang.ClassLoader
Parameters:
name - Complete class name
resolve - Boolean look up remotely.
Throws:
java.lang.ClassNotFoundException - Problem with the loaded class: not found.