|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectvisidia.simulation.process.messages.Message
public abstract class Message
This is the abstract base class representing the messages exchanged between the network nodes. To avoid cross-references (different nodes owning a reference to the same Message), messages must be cloned before being added to the receiver queue.
Constructor Summary | |
---|---|
Message()
|
Method Summary | |
---|---|
abstract java.lang.Object |
clone()
Gives a copy (a clone) of this object. |
abstract java.lang.Object |
getData()
Each message has a data which can be accessed by the getData() method. |
int |
getMsgClock()
This method allows the user to get the time at which the message has been sent. |
MessageType |
getType()
gets the message type. |
boolean |
getVisualization()
Checks if the message is to be visualized. |
void |
setMsgClock(int value)
This method allows the user to set the time at which the message is sent. |
void |
setType(MessageType type)
This method sets the type of a message. |
void |
setVisualization(boolean s)
Sets if the message is to be visualized. |
abstract java.lang.String |
toString()
Returns a string representation of the message. |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Message()
Method Detail |
---|
public void setMsgClock(int value)
value
- the valuepublic int getMsgClock()
public void setType(MessageType type)
type
- the typepublic MessageType getType()
public abstract java.lang.Object getData()
public abstract java.lang.String toString()
toString
in class java.lang.Object
public boolean getVisualization()
public void setVisualization(boolean s)
s
- true if the message is to be visualized; false otherwisepublic abstract java.lang.Object clone()
clone
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |