code: private Map<Resourcepart, Presence> getPresencesInternal(BareJid entity) {
          Map<Resourcepart, Presence> entityPresences = presenceMap.get(entity);
          if (entityPresences == null) {
              entityPresences = nonRosterPresenceMap.lookup(entity);
          }
          return entityPresences;
      }
docs: Retrieve the user presences (a map from resource to {@link Presence}) for a given XMPP entity represented by their bare JID.
  
  @param entity the entity
  @return the user presences