All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class tos.Carrier


public abstract class Carrier
extends Object
This class is the placeholder for carrier implementations. It is an abstract class, hence it must be subclassed by programmers before any carrier instances can be made. More specifically, the begin method must be implemented.

Note: Subclasses of this class should be self-contained, meaning that they should not reference any classes not being part of the Java base system.

Note: Subclasses providing any constructors must also provide the default constructor (i.e. the one taking no arguments).

A simple subclass might look something like this:

   public class Hello extends Carrier {
     public void begin() {
       System.err.println("Hello, World!!");

$Id:,v 1.3 2000/11/16 15:35:10 lauvset Exp $
Kåre Jørgen Lauvset []

Variable Index

 o data
Carrier data.
 o path
Carrier path.

Constructor Index

 o Carrier()
Initialize carrier.

Method Index

 o begin()
Carrier entry point.


 o data
 public Hashtable data
Carrier data. The objects stored in this collection move along when the carrier moves.

Note: All stored objects should be serializable (i.e. implement the interface).

 o path
 public Vector path
Carrier path. The path is an ordered list of host names.

Note: Only strings should be stored in the list.


 o Carrier
 public Carrier()
Initialize carrier. Empty data and path structures are created.


 o begin
 public abstract void begin() throws Exception
Carrier entry point. This method is executed at every host the carrier visits.

Throws: Exception
if the carrier does not catch its own exceptions.

Note: Any exception thrown is stored in the variable status of the shell executing the carrier.

All Packages  Class Hierarchy  This Package  Previous  Next  Index