gov.sandia.ccaffeine.dc.user_iface.MVC.event
Class MessageEvent

java.lang.Object
  extended by java.util.EventObject
      extended by gov.sandia.ccaffeine.dc.user_iface.MVC.event.MessageEvent
All Implemented Interfaces:
java.io.Serializable

public class MessageEvent
extends java.util.EventObject

Used to notify components that the cca server sent a message to this client. For example, a server might respond to a "go" command by sending a message. A view entity might respond by printing a string on standard out.

Possible Scenario
The end-user clicked on one of the GO ports
The cca server executes the GO command
The cca server sends a Message to this client
The client responds by displaying the message in standard out.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
MessageEvent(java.lang.Object source)
          Create a MessageEvent.
MessageEvent(java.lang.Object source, java.lang.String message)
          Create a MessageEvent.
 
Method Summary
 java.lang.String getMessage()
          Return the contents of the message
 void setMessage(java.lang.String message)
          Set the contents of the message.
 
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

MessageEvent

public MessageEvent(java.lang.Object source)
Create a MessageEvent. This event can be used to notify components that the cca server sent a message to this client. For example, a server might respond to a "go" command by sending a message. A view entity might respond by printing a string on standard out.

Parameters:
source - the entity that created this MessageEvent.

MessageEvent

public MessageEvent(java.lang.Object source,
                    java.lang.String message)
Create a MessageEvent. This event can be used to notify components that the cca server sent a message to this client. For example, a server might respond to a "go" command by sending a message. A view entity might respond by printing a string on standard out.

Parameters:
source - the entity that created this MessageEvent.
Method Detail

getMessage

public java.lang.String getMessage()
Return the contents of the message

Returns:
The contents of the message

setMessage

public void setMessage(java.lang.String message)
Set the contents of the message.

Parameters:
message - the contents of the message