com.threerings.crowd.chat.data
Class ChatMessage

java.lang.Object
  extended by com.threerings.crowd.chat.data.ChatMessage
All Implemented Interfaces:
Streamable
Direct Known Subclasses:
SystemMessage, UserMessage

public abstract class ChatMessage
extends Object
implements Streamable

The abstract base class of all the client-side ChatMessage objects.


Nested Class Summary
 
Nested classes/interfaces inherited from interface com.threerings.io.Streamable
Streamable.Closure
 
Field Summary
 String bundle
          The bundle to use when translating this message.
 String localtype
          The client side 'localtype' of this chat, set to the type registered with an auxiliary source in the ChatDirector.
 String message
          The actual text of the message.
 long timestamp
          The client time that this message was created.
 
Constructor Summary
ChatMessage(String message, String bundle)
          Construct a ChatMessage.
 
Method Summary
 String getFormat()
          Get the appropriate message format for this message.
 void setClientInfo(String msg, String ltype)
          Once this message reaches the client, the information contained within is changed around a bit.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

message

public String message
The actual text of the message.


bundle

public String bundle
The bundle to use when translating this message.


localtype

public transient String localtype
The client side 'localtype' of this chat, set to the type registered with an auxiliary source in the ChatDirector.


timestamp

public transient long timestamp
The client time that this message was created.

Constructor Detail

ChatMessage

public ChatMessage(String message,
                   String bundle)
Construct a ChatMessage.

Method Detail

setClientInfo

public void setClientInfo(String msg,
                          String ltype)
Once this message reaches the client, the information contained within is changed around a bit.


getFormat

public String getFormat()
Get the appropriate message format for this message.


toString

public String toString()
Overrides:
toString in class Object