tigase.jaxmpp.core.client.xmpp.modules.roster

## Class DefaultRosterStore

- java.lang.Object
- - tigase.jaxmpp.core.client.xmpp.modules.roster.RosterStore
  - - tigase.jaxmpp.core.client.xmpp.modules.roster.DefaultRosterStore

- All Implemented Interfaces:
    Property
  Direct Known Subclasses:
    GwtRosterStore

      public class DefaultRosterStore
      extends RosterStore

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from class tigase.jaxmpp.core.client.xmpp.modules.roster.RosterStore

      `RosterStore.Predicate`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected Set<String>` | `groups`
    `protected Map<BareJID,RosterItem>` | `roster`

    - ### Fields inherited from class tigase.jaxmpp.core.client.xmpp.modules.roster.RosterStore

      `sessionObject`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `DefaultRosterStore()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected Set<String>` | `addItem(RosterItem item)`
    `protected Set<String>` | `calculateModifiedGroups(HashSet<String> groupsOld)`
    `protected int` | `createItemId(BareJID jid)`
    `RosterItem` | `get(BareJID jid)` Returns RosterItem of given bare JID.
    `List<RosterItem>` | `getAll(RosterStore.Predicate predicate)` Returns all roster items selected by selector.
    `int` | `getCount()` Returns number of roster items in storage.
    `Collection<? extends String>` | `getGroups()` Get all known groups of buddies.
    `void` | `removeAll()`
    `protected void` | `removeItem(BareJID jid)`

    - ### Methods inherited from class tigase.jaxmpp.core.client.xmpp.modules.roster.RosterStore

      `add, add, add, clear, getAll, getPropertyClass, remove, setSessionObject, update`

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

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

- - ### Field Detail

    - #### groups

          protected final Set<String> groups

    - #### roster

          protected final Map<BareJID,RosterItem> roster

  - ### Constructor Detail

    - #### DefaultRosterStore

          public DefaultRosterStore()

  - ### Method Detail

    - #### addItem

          protected Set<String> addItem(RosterItem item)

      Specified by:
        `addItem` in class `RosterStore`

    - #### calculateModifiedGroups

          protected Set<String> calculateModifiedGroups(HashSet<String> groupsOld)

      Specified by:
        `calculateModifiedGroups` in class `RosterStore`

    - #### createItemId

          protected int createItemId(BareJID jid)

    - #### get

          public RosterItem get(BareJID jid)

      Returns RosterItem of given bare JID.
      Specified by:
        `get` in class `RosterStore`
      Parameters:
        `jid` - bare JID.
      Returns:
        roster item.

    - #### getAll

          public List<RosterItem> getAll(RosterStore.Predicate predicate)

      Returns all roster items selected by selector.
      Specified by:
        `getAll` in class `RosterStore`
      Parameters:
        `predicate` - selector.
      Returns:
        all matched roster items.

    - #### getCount

          public int getCount()

      Returns number of roster items in storage.
      Specified by:
        `getCount` in class `RosterStore`
      Returns:
        number of roster items in storage.

    - #### getGroups

          public Collection<? extends String> getGroups()

      Get all known groups of buddies.
      Specified by:
        `getGroups` in class `RosterStore`
      Returns:
        collection of group names.

    - #### removeAll

          public void removeAll()

      Specified by:
        `removeAll` in class `RosterStore`

    - #### removeItem

          protected void removeItem(BareJID jid)

      Specified by:
        `removeItem` in class `RosterStore`

Copyright © 2006–2023 Tigase. All rights reserved.