All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class sics.agentbase.core.NetworkClassLoader

java.lang.Object
   |
   +----java.lang.ClassLoader
           |
           +----sics.agentbase.core.BasicClassLoader
                   |
                   +----sics.agentbase.core.NetworkClassLoader

public class NetworkClassLoader
extends BasicClassLoader
The NetworkClassLoader is used to load classes using a URL. At construction time a URL is specified, and this URL is used for all subsequent class loading with that class loader object.

See Also:
ClassLoader, BasicClassLoader

Constructor Index

 o NetworkClassLoader(String)
Constructs a NetworkClassLoader for loading classes from the specified URL.

Method Index

 o loadClassBytes(String)
Loads a file from a URL into an array of bytes.

Constructors

 o NetworkClassLoader
 public NetworkClassLoader(String root_url)
Constructs a NetworkClassLoader for loading classes from the specified URL.

Parameters:
root - The root URL to use for all class loading. Should end with a "/".

Methods

 o loadClassBytes
 protected byte[] loadClassBytes(String name)
Loads a file from a URL into an array of bytes. The '.' in the class name are replaced by '/' so as to map into the right package directory on the remote host.

Parameters:
url - The URL to the file.
Returns:
An array of the bytes in the file.
Overrides:
loadClassBytes in class BasicClassLoader

All Packages  Class Hierarchy  This Package  Previous  Next  Index