|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--SimKit.LP
This is the Logical Process (LP) abstract base class. All
the components of a model are defined by extending this class.
To aid in debugging, each LP object is assigned an integer ID.
The toString() function returns a tag with the ID number in it.
The classes that extend LP should augment the toString() method
to print out testing and debug information.
Extending this class ...
The functions initialize(), terminate() may be overridden.
The process(Event) must be provided, as it is an abstract
method. Also, the default constructor must be invoked
from subclass constructors.
Event
,
Simulation
Constructor Summary | |
LP()
This constructor must be called by classes extending from LP. |
Method Summary | |
Event |
copy_and_delete()
Should be called when for performance reasons instead of creating a new Event via new operator the same received Event object is used. |
int |
indexNumber()
Report the unique index number for this LP. |
void |
initialize()
Initialization routine. |
abstract void |
process(Event event)
The process() function is the most important function for the LP class. |
void |
terminate()
Termination routine. |
java.lang.String |
toString()
Generate a textual description of the LP object. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public LP()
Method Detail |
public void initialize()
public void terminate()
public abstract void process(Event event)
event
- The event that the LP has just received.public Event copy_and_delete()
public int indexNumber()
public java.lang.String toString()
toString
in class java.lang.Object
return(super.toString() + "My extra information ");
indexNumber()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |