tigase.jaxmpp.core.client.xmpp.modules.chat.xep0085

## Class ChatStateExtension

- java.lang.Object
- - tigase.jaxmpp.core.client.xmpp.modules.chat.xep0085.ChatStateExtension

- All Implemented Interfaces:
    EventHandler, JaxmppCore.LoggedOutHandler, MessageModule.ChatClosedHandler, ContextAware, Extension

      public class ChatStateExtension
      extends Object
      implements Extension, ContextAware, MessageModule.ChatClosedHandler, JaxmppCore.LoggedOutHandler

  Author:
    andrzej

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static interface` | `ChatStateExtension.ChatStateChangedHandler`

    - ### Nested classes/interfaces inherited from interface tigase.jaxmpp.core.client.xmpp.modules.chat.MessageModule.ChatClosedHandler

      `MessageModule.ChatClosedHandler.ChatClosedEvent`

    - ### Nested classes/interfaces inherited from interface tigase.jaxmpp.core.client.JaxmppCore.LoggedOutHandler

      `JaxmppCore.LoggedOutHandler.LoggedOutEvent`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static String` | `CHAT_STATE_DISABLED_KEY`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ChatStateExtension(AbstractChatManager chatManager)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `Element` | `afterReceive(Element received)`
    `Element` | `beforeSend(Element received)`
    `String[]` | `getFeatures()`
    `ChatState` | `getRecipientChatState(Chat chat)`
    `static boolean` | `isDisabled(SessionObject sessionObject)`
    `void` | `onChatClosed(SessionObject sessionObject, Chat chat)`
    `void` | `onLoggedOut(SessionObject sessionObject)` Called when LoggedOutEvent is fired.
    `void` | `setContext(Context context)`
    `void` | `setDisabled(boolean disabled)`
    `void` | `setOwnChatState(Chat chat, ChatState state)`

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

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### CHAT_STATE_DISABLED_KEY

          public static final String CHAT_STATE_DISABLED_KEY

      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### ChatStateExtension

          public ChatStateExtension(AbstractChatManager chatManager)

  - ### Method Detail

    - #### isDisabled

          public static boolean isDisabled(SessionObject sessionObject)

    - #### afterReceive

          public Element afterReceive(Element received)
                               throws JaxmppException

      Specified by:
        `afterReceive` in interface `Extension`
      Throws:
        `JaxmppException`

    - #### beforeSend

          public Element beforeSend(Element received)
                             throws JaxmppException

      Specified by:
        `beforeSend` in interface `Extension`
      Throws:
        `JaxmppException`

    - #### getFeatures

          public String[] getFeatures()

      Specified by:
        `getFeatures` in interface `Extension`

    - #### getRecipientChatState

          public ChatState getRecipientChatState(Chat chat)

    - #### onChatClosed

          public void onChatClosed(SessionObject sessionObject,
                                   Chat chat)

      Specified by:
        `onChatClosed` in interface `MessageModule.ChatClosedHandler`

    - #### onLoggedOut

          public void onLoggedOut(SessionObject sessionObject)

      Description copied from interface: `JaxmppCore.LoggedOutHandler`
      Called when LoggedOutEvent is fired.
      Specified by:
        `onLoggedOut` in interface `JaxmppCore.LoggedOutHandler`
      Parameters:
        `sessionObject` - session object related to connection.

    - #### setContext

          public void setContext(Context context)

      Specified by:
        `setContext` in interface `ContextAware`

    - #### setDisabled

          public void setDisabled(boolean disabled)

    - #### setOwnChatState

          public void setOwnChatState(Chat chat,
                                      ChatState state)
                               throws JaxmppException

      Throws:
        `JaxmppException`

Copyright © 2006–2019 Tigase. All rights reserved.