tigase.jaxmpp.core.client.xmpp.stanzas

## Class Presence

- 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.Presence

- All Implemented Interfaces:
    Element

      public class Presence
      extends Stanza

  Representation of Presence stanza.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `Presence.Show` Availability sub-state

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

      `Stanza.UnkownStanzaTypeException`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static Presence` | `create()` Creates new instance of stanza.
    `String` | `getNickname()` Returns nickname.
    `Integer` | `getPriority()` Returns priority level of resource.
    `Presence.Show` | `getShow()` Return avaiability substate.
    `String` | `getStatus()` Returns natural-language description of an entity's availability.
    `void` | `setNickname(String nickname)` Sets nickname.
    `void` | `setPriority(Integer value)` Sets priority level of resource.
    `void` | `setShow(Presence.Show show)` Sets avaiability sub-state.
    `void` | `setStatus(String status)` Sets natural-language description of an entity's availability.

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

      `addFlag, canBeConverted, create, createIQ, createMessage, createPresence, getErrorCondition, getErrorMessage, getFrom, getId, getTo, getType, 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`

- - ### Method Detail

    - #### create

          public static Presence create()
                                 throws JaxmppException

      Creates new instance of stanza.
      Returns:
        Presence
      Throws:
        `JaxmppException`

    - #### getNickname

          public String getNickname()
                             throws XMLException

      Returns nickname. Nickname is defined in XEP-0172: User Nickname.
      Returns:
        nickname or `null` if not present.
      Throws:
        `XMLException`

    - #### setNickname

          public void setNickname(String nickname)
                           throws XMLException

      Sets nickname. Nickname is defined in XEP-0172: User Nickname.
      Parameters:
        `nickname` - nickname
      Throws:
        `XMLException`

    - #### getPriority

          public Integer getPriority()
                              throws XMLException

      Returns priority level of resource.
      Returns:
        priority level.
      Throws:
        `XMLException`

    - #### setPriority

          public void setPriority(Integer value)
                           throws XMLException

      Sets priority level of resource.
      Parameters:
        `value` -
      Throws:
        `XMLException`

    - #### getShow

          public Presence.Show getShow()
                                throws XMLException

      Return avaiability substate.
      Returns:
        Presence.Show
      Throws:
        `XMLException`

    - #### setShow

          public void setShow(Presence.Show show)
                       throws XMLException

      Sets avaiability sub-state.
      Parameters:
        `show` - Presence.Show
      Throws:
        `XMLException`

    - #### getStatus

          public String getStatus()
                           throws XMLException

      Returns natural-language description of an entity's availability.
      Returns:
        status
      Throws:
        `XMLException`

    - #### setStatus

          public void setStatus(String status)
                         throws XMLException

      Sets natural-language description of an entity's availability.
      Parameters:
        `status` - description
      Throws:
        `XMLException`

Copyright © 2006–2020 Tigase. All rights reserved.