Package org.xwiki.user.group
Interface GroupManager
-
@Role public interface GroupManagerFast access to group membership.- Since:
- 10.8RC1
- Version:
- $Id: d525a26a25e08efefe69d63c6df8ded2451e6d99 $
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Collection<DocumentReference>getGroups(DocumentReference member, Object wikiTarget, boolean recurse)Search groups the passed user or group is member of.Collection<DocumentReference>getMembers(DocumentReference group, boolean recurse)Retrieve the users and groups which are the members of the passed group.
-
-
-
Method Detail
-
getGroups
Collection<DocumentReference> getGroups(DocumentReference member, Object wikiTarget, boolean recurse) throws GroupException
Search groups the passed user or group is member of.{code wikis} controls where to search for the groups and
recurseonly the direct group should be returned or the whole hierarchy.- Parameters:
member- the group member (user or group)wikiTarget- the wikis where to search. The following types are supported:WikiTargetStringCollection<String>org.xwiki.model.reference.WikiReferenceCollection<org.xwiki.model.reference.WikiReference>
recurse- false if only the direct groups should be returned, true to take into account groups of groups- Returns:
- the groups the passed user or group is member of
- Throws:
GroupException- when failing to get groups
-
getMembers
Collection<DocumentReference> getMembers(DocumentReference group, boolean recurse) throws GroupException
Retrieve the users and groups which are the members of the passed group.- Parameters:
group- the group for which to return the membersrecurse- false if only the direct members should be returned, true to take into account groups of groups- Returns:
- the members of the passed group
- Throws:
GroupException- when failing to get members
-
-