org.gwtwidgets.client.stream
Class Message

java.lang.Object
  extended by org.gwtwidgets.client.stream.Message

public class Message
extends java.lang.Object

Models a message sent over the streaming protocol

Author:
George Georgovassilis, g.georgovassilis[at]gmail.com

Constructor Summary
Message()
           
 
Method Summary
 java.util.Map<java.lang.String,java.lang.String> getAttributes()
          Returns reference to the message attribute map.
 java.lang.String getContent()
          Message content.
 int getSerialNumber()
           
 boolean isEOF()
          True if this is the last message in the stream
 void setAttributes(java.util.Map<java.lang.String,java.lang.String> attributes)
           
 void setContent(java.lang.String content)
           
 void setEOF(boolean eof)
           
 void setSerialNumber(int serialNumber)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Message

public Message()
Method Detail

isEOF

public boolean isEOF()
True if this is the last message in the stream

Returns:

setEOF

public void setEOF(boolean eof)

getContent

public java.lang.String getContent()
Message content. Can be any valid string.

Returns:

setContent

public void setContent(java.lang.String content)

getAttributes

public java.util.Map<java.lang.String,java.lang.String> getAttributes()
Returns reference to the message attribute map. Message attributes can be any set of key/value pairs.

Returns:

getSerialNumber

public int getSerialNumber()

setSerialNumber

public void setSerialNumber(int serialNumber)

setAttributes

public void setAttributes(java.util.Map<java.lang.String,java.lang.String> attributes)

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2011. All Rights Reserved.