tigase.jaxmpp.core.client.xmpp.stanzas

## Class Message

- java.lang.Object
- - tigase.jaxmpp.core.client.xml.ElementWrapper
  - - tigase.jaxmpp.core.client.xmpp.stanzas.StreamPacket
    - - tigase.jaxmpp.core.client.xmpp.stanzas.Stanza
      - - tigase.jaxmpp.core.client.xmpp.stanzas.Message

- All Implemented Interfaces:
    Element
  Direct Known Subclasses:
    OMEMOEncryptableMessage, OMEMOMessage

      public class Message
      extends Stanza

  Representation od Message stanza.

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from class tigase.jaxmpp.core.client.xmpp.stanzas.Stanza

      `Stanza.UnkownStanzaTypeException`

  - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `Message(Element element)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static Message` | `create()`
    `String` | `getBody()` Return message body.
    `String` | `getSubject()` Returns subject of message.
    `String` | `getThread()` Returns thread-id.
    `StanzaType` | `getType()` Returns type of stanza.
    `void` | `setBody(String body)` Sets body of message.
    `void` | `setSubject(String subject)` Sets subject of message.
    `void` | `setThread(String thread)` Sets thread-id of message.

    - ### Methods inherited from class tigase.jaxmpp.core.client.xmpp.stanzas.Stanza

      `addFlag, canBeConverted, create, createIQ, createMessage, createPresence, getErrorCondition, getErrorMessage, getFrom, getId, getTo, getType, hasFlag, removeFlag, setFrom, setId, setTo, setType`

    - ### Methods inherited from class tigase.jaxmpp.core.client.xmpp.stanzas.StreamPacket

      `getXmppStream, setXmppStream`

    - ### Methods inherited from class tigase.jaxmpp.core.client.xml.ElementWrapper

      `addChild, equals, findChild, getAsString, getAttribute, getAttributes, getChildAfter, getChildElementValue, getChildElementValue, getChildren, getChildren, getChildrenNS, getChildrenNS, getFirstChild, getFirstChild, getName, getNextSibling, getParent, getValue, getWrappedElement, getXMLNS, hashCode, removeAttribute, removeChild, setAttribute, setAttributes, setChildElementValue, setChildElementValue, setParent, setValue, setXMLNS, toString`

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### Message

          protected Message(Element element)
                     throws XMLException

      Throws:
        `XMLException`

  - ### Method Detail

    - #### create

          public static final Message create()
                                      throws JaxmppException

      Throws:
        `JaxmppException`

    - #### getBody

          public String getBody()
                         throws XMLException

      Return message body.
      Returns:
        message body.
      Throws:
        `XMLException`

    - #### setBody

          public void setBody(String body)
                       throws XMLException

      Sets body of message.
      Parameters:
        `body` - body of message
      Throws:
        `XMLException`

    - #### getSubject

          public String getSubject()
                            throws XMLException

      Returns subject of message.
      Returns:
        subject of message
      Throws:
        `XMLException`

    - #### setSubject

          public void setSubject(String subject)
                          throws XMLException

      Sets subject of message.
      Parameters:
        `subject` - subject of message
      Throws:
        `XMLException`

    - #### getThread

          public String getThread()
                           throws XMLException

      Returns thread-id.
      Returns:
        thread-id
      Throws:
        `XMLException`

    - #### setThread

          public void setThread(String thread)
                         throws XMLException

      Sets thread-id of message.
      Parameters:
        `thread` - thread-id
      Throws:
        `XMLException`

    - #### getType

          public StanzaType getType()
                             throws XMLException

      Returns type of stanza.
      Overrides:
        `getType` in class `Stanza`
      Returns:
        StanzaType. `null` if type not present.
      Throws:
        `XMLException`

Copyright © 2006–2023 Tigase. All rights reserved.