springs.communication
Class Message

java.lang.Object
  |
  +--springs.communication.Message
All Implemented Interfaces:
java.io.Serializable

public class Message
extends java.lang.Object
implements java.io.Serializable

Interface to a Springs agent.

Author:
Sergio Ilarri Artigas
See Also:
Serialized Form

Field Summary
private  java.lang.Object _contents
          The contents of the message.
private  java.lang.String _sender
          The sender of the message.
private  java.lang.String _subject
          The subject of the message.
private  java.lang.String _type
          The type of the message.
 
Constructor Summary
Message(java.lang.String type, java.lang.String sender, java.lang.String subject, java.lang.Object contents)
          Constructor.
 
Method Summary
 java.lang.Object getContents()
          Obtains the contents of the message.
 java.lang.String getSender()
          Obtains the sender of the message.
 java.lang.String getSubject()
          Obtains the subject of the message.
 java.lang.String getType()
          Obtains the type of the message.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_type

private java.lang.String _type
The type of the message.

See Also:
String

_sender

private java.lang.String _sender
The sender of the message.

See Also:
String

_subject

private java.lang.String _subject
The subject of the message.

See Also:
String

_contents

private java.lang.Object _contents
The contents of the message.

See Also:
Object
Constructor Detail

Message

public Message(java.lang.String type,
               java.lang.String sender,
               java.lang.String subject,
               java.lang.Object contents)
Constructor.

Parameters:
type - the type of the message.
contents - the contents.
See Also:
String, Object
Method Detail

getType

public java.lang.String getType()
Obtains the type of the message.

Returns:
the type.
See Also:
String

getContents

public java.lang.Object getContents()
Obtains the contents of the message.

Returns:
the contents.
See Also:
Object

getSender

public java.lang.String getSender()
Obtains the sender of the message.

Returns:
the sender.
See Also:
String

getSubject

public java.lang.String getSubject()
Obtains the subject of the message.

Returns:
the subject.
See Also:
String