public final class BlockingManager extends ExtensionManager
Enabling or disabling this manager has no effect, because blocking is done on server side.
features, xmppSession| Modifier and Type | Method and Description |
|---|---|
void |
addBlockingListener(BlockingListener blockingListener)
Adds a blocking listener, which allows to listen for block and unblock pushes.
|
void |
blockContact(rocks.xmpp.core.Jid... jids)
Blocks communications with contacts.
|
Collection<rocks.xmpp.core.Jid> |
getBlockedContacts()
Retrieves the blocked contacts.
|
void |
removeBlockingListener(BlockingListener blockingListener)
Removes a previously added blocking listener.
|
void |
unblockContact(rocks.xmpp.core.Jid... jids)
Unblocks communications with specific contacts or with all contacts.
|
setEnabledpublic void addBlockingListener(BlockingListener blockingListener)
blockingListener - The listener.removeBlockingListener(BlockingListener)public void removeBlockingListener(BlockingListener blockingListener)
blockingListener - The listener.addBlockingListener(BlockingListener)public Collection<rocks.xmpp.core.Jid> getBlockedContacts() throws rocks.xmpp.core.XmppException
rocks.xmpp.core.stanza.model.StanzaException - If the entity returned a stanza error.NoResponseException - If the entity did not respond.rocks.xmpp.core.XmppExceptionpublic void blockContact(rocks.xmpp.core.Jid... jids)
throws rocks.xmpp.core.XmppException
jids - The contacts.rocks.xmpp.core.stanza.model.StanzaException - If the entity returned a stanza error.NoResponseException - If the entity did not respond.rocks.xmpp.core.XmppExceptionpublic void unblockContact(rocks.xmpp.core.Jid... jids)
throws rocks.xmpp.core.XmppException
jids - The contacts.rocks.xmpp.core.stanza.model.StanzaException - If the entity returned a stanza error.NoResponseException - If the entity did not respond.rocks.xmpp.core.XmppExceptionCopyright © 2014 XMPP.rocks. All rights reserved.