eneter.messaging.messagingsystems.connectionprotocols
Class ProtocolMessage

java.lang.Object
  extended by eneter.messaging.messagingsystems.connectionprotocols.ProtocolMessage

public class ProtocolMessage
extends java.lang.Object

Message decoded by the protocol formatter. The protocol formatter is used for the internal communication between output and input channel. When the channel receives a message it uses the protocol formatter to figure out if is is 'Open Connection', 'Close Connection' or 'Data Message'.
Protocol formatter decodes the message and returns ProtocolMessage.


Field Summary
 java.lang.Object Message
          If message type is MessageReceived the it contains the serialized message data.
 EProtocolMessageType MessageType
          Type of the message.
 java.lang.String ResponseReceiverId
          Client id.
 
Constructor Summary
ProtocolMessage()
          Default constructor.
ProtocolMessage(EProtocolMessageType messageType, java.lang.String responseReceiverId, java.lang.Object message)
          Constructs the protocol message from the given parameters.
 
Method Summary
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MessageType

public EProtocolMessageType MessageType
Type of the message.


ResponseReceiverId

public java.lang.String ResponseReceiverId
Client id.


Message

public java.lang.Object Message
If message type is MessageReceived the it contains the serialized message data. Otherwise it is null.

Constructor Detail

ProtocolMessage

public ProtocolMessage()
Default constructor.


ProtocolMessage

public ProtocolMessage(EProtocolMessageType messageType,
                       java.lang.String responseReceiverId,
                       java.lang.Object message)
Constructs the protocol message from the given parameters.

Parameters:
messageType - type of the message
responseReceiverId - client id
message - message content