org.gwtwidgets.client.stream
Class Message

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

public class Message
extends Object

Models a message sent over the streaming protocol

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

Constructor Summary
Message()
           
 
Method Summary
 Map<String,String> getAttributes()
          Returns reference to the message attribute map.
 String getContent()
          Message content.
 int getSerialNumber()
           
 boolean isEOF()
          True if this is the last message in the stream
 void setAttributes(Map<String,String> attributes)
           
 void setContent(String content)
           
 void setEOF(boolean eof)
           
 void setSerialNumber(int serialNumber)
           
 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 String getContent()
Message content. Can be any valid string.

Returns:

setContent

public void setContent(String content)

getAttributes

public Map<String,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(Map<String,String> attributes)

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2011. All Rights Reserved.