jsim.jmessage
Class JsimEvent

java.lang.Object
  extended by java.util.EventObject
      extended by jsim.jmessage.JsimEvent
All Implemented Interfaces:
java.io.Serializable

public class JsimEvent
extends java.util.EventObject
implements java.io.Serializable

This class provides general events for Jsim. If the event does not have special requirements, it can be an instance of this class; otherwise, a class should be derived from this one.

See Also:
Serialized Form

Constructor Summary
JsimEvent(java.lang.Object source, long eventID, java.lang.Object handback)
          Construct a JsimEvent.
 
Method Summary
 java.lang.String getEventType()
          Returns the name of the event type (rather than just the ID).
 long getID()
          Returns the event ID.
 java.lang.Object getRegistrationObject()
          Returns the event registration object.
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

JsimEvent

public JsimEvent(java.lang.Object source,
                 long eventID,
                 java.lang.Object handback)
Construct a JsimEvent.

Parameters:
source - The source of this event
eventID - The global ID of this event
seqNum - The sequence number (needed in distributed enrionment
handback - The event registration object carrying event data
Method Detail

getID

public long getID()
Returns the event ID.

Returns:
long The event ID

getEventType

public java.lang.String getEventType()
Returns the name of the event type (rather than just the ID).

Returns:
String Name/type of the event

getRegistrationObject

public java.lang.Object getRegistrationObject()
Returns the event registration object.

Returns:
Object The event registration object