public class ChatStateExtension extends Object implements Extension, ContextAware, MessageModule.ChatClosedHandler, JaxmppCore.LoggedOutHandler
Modifier and Type | Class and Description |
---|---|
static interface |
ChatStateExtension.ChatStateChangedHandler |
MessageModule.ChatClosedHandler.ChatClosedEvent
JaxmppCore.LoggedOutHandler.LoggedOutEvent
Modifier and Type | Field and Description |
---|---|
static String |
CHAT_STATE_DISABLED_KEY |
Constructor and Description |
---|
ChatStateExtension(AbstractChatManager chatManager) |
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) |
public static final String CHAT_STATE_DISABLED_KEY
public ChatStateExtension(AbstractChatManager chatManager)
public static boolean isDisabled(SessionObject sessionObject)
public Element afterReceive(Element received) throws JaxmppException
afterReceive
in interface Extension
JaxmppException
public Element beforeSend(Element received) throws JaxmppException
beforeSend
in interface Extension
JaxmppException
public String[] getFeatures()
getFeatures
in interface Extension
public void onChatClosed(SessionObject sessionObject, Chat chat)
onChatClosed
in interface MessageModule.ChatClosedHandler
public void onLoggedOut(SessionObject sessionObject)
JaxmppCore.LoggedOutHandler
onLoggedOut
in interface JaxmppCore.LoggedOutHandler
sessionObject
- session object related to connection.public void setContext(Context context)
setContext
in interface ContextAware
public void setDisabled(boolean disabled)
public void setOwnChatState(Chat chat, ChatState state) throws JaxmppException
JaxmppException
Copyright © 2006–2023 Tigase. All rights reserved.