org.jivesoftware.xiff.data
class Message
Object
|
+--org.jivesoftware.xiff.data.XMLStanza
|
+--org.jivesoftware.xiff.data.XMPPStanza
|
+--org.jivesoftware.xiff.data.Message
Implemented Interfaces: ISerializableclass Message extends XMPPStanza
A class for abstraction and encapsulation of message data.
- Author:Sean Voisen # @since 2.0.0
Fields inherited from class org.jivesoftware.xiff.data.XMPPStanza
Fields inherited from class org.jivesoftware.xiff.data.XMLStanza
Property Summary
The message body in plain-text format. If a client cannot render HTML-formatted text, this text is typically used instead.
The message body in XHTML format. Internally, this uses the XHTML data extension.
The message subject. Typically chat and groupchat-type messages do not use subjects. Rather, this is reserved for normal and headline-type messages.
The message thread ID. Threading is used to group messages of the same discussion together. The library does not perform message grouping, rather it is up to any client authors to properly perform this task.
Properties inherited from class org.jivesoftware.xiff.data.XMPPStanza
Constructor
public Message (
recipient: String, msgID: String, msgBody: String, msgHTMLBody: String, msgType: String, msgSubject: String)
Method Summary
Deserializes an XML object and populates the Message instance with its data.
Serializes the Message into XML form for sending to a server.
Methods inherited from class org.jivesoftware.xiff.data.XMPPStanza
Methods inherited from class org.jivesoftware.xiff.data.XMLStanza
Field Documentation
Property Documentation
body
public body: String (read, write)
The message body in plain-text format. If a client cannot render HTML-formatted text, this text is typically used instead.
htmlBody
public htmlBody: String (read, write)
The message body in XHTML format. Internally, this uses the XHTML data extension.
subject
public subject: String (read, write)
The message subject. Typically chat and groupchat-type messages do not use subjects. Rather, this is reserved for normal and headline-type messages.
thread
public thread: String (read, write)
The message thread ID. Threading is used to group messages of the same discussion together. The library does not perform message grouping, rather it is up to any client authors to properly perform this task.
Constructor Documentation
Message
public function Message (
recipient: String,
msgID: String,
msgBody: String,
msgHTMLBody: String,
msgType: String,
msgSubject: String)
msgID: String,
msgBody: String,
msgHTMLBody: String,
msgType: String,
msgSubject: String)
Method Documentation
deserialize
public function deserialize (
xmlNode: XMLNode): Boolean
Deserializes an XML object and populates the Message instance with its data.
- Specified by:deserialize in interface ISerializable
- Overrides:XMPPStanza.deserialize in class XMPPStanza
- Parameters:
xmlNode The XML to deserialize - Returns:An indication as to whether deserialization was sucessful
serialize
public function serialize (
parentNode: XMLNode): Boolean
Serializes the Message into XML form for sending to a server.
- Specified by:serialize in interface ISerializable
- Overrides:XMPPStanza.serialize in class XMPPStanza
- Parameters:
parentNode (XMLNode) The container of the XML. - Returns:An indication as to whether serialization was successful
- Message.as, Last Modified: 3/10/2005 10:15:44 PM