Class SharedGroupManager


  • public class SharedGroupManager
    extends java.lang.Object
    A SharedGroupManager provides services for discovering the shared groups where a user belongs.

    Important note: This functionality is not part of the XMPP spec and it will only work with Wildfire.

    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.util.List<java.lang.String> getSharedGroups​(org.jivesoftware.smack.XMPPConnection connection)
      Returns the collection that will contain the name of the shared groups where the user logged in with the specified session belongs.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • SharedGroupManager

        public SharedGroupManager()
    • Method Detail

      • getSharedGroups

        public static java.util.List<java.lang.String> getSharedGroups​(org.jivesoftware.smack.XMPPConnection connection)
                                                                throws org.jivesoftware.smack.SmackException.NoResponseException,
                                                                       org.jivesoftware.smack.XMPPException.XMPPErrorException,
                                                                       org.jivesoftware.smack.SmackException.NotConnectedException,
                                                                       java.lang.InterruptedException
        Returns the collection that will contain the name of the shared groups where the user logged in with the specified session belongs.
        Parameters:
        connection - connection to use to get the user's shared groups.
        Returns:
        collection with the shared groups' name of the logged user.
        Throws:
        org.jivesoftware.smack.XMPPException.XMPPErrorException - if there was an XMPP error returned.
        org.jivesoftware.smack.SmackException.NoResponseException - if there was no response from the remote entity.
        org.jivesoftware.smack.SmackException.NotConnectedException - if the XMPP connection is not connected.
        java.lang.InterruptedException - if the calling thread was interrupted.