public interface MembershipDao
Modifier and Type | Method and Description |
---|---|
BatchResult<String> |
addAllUsersToGroup(long directoryId,
Collection<String> userNames,
String groupName)
Adds all the given users into the given group.
|
void |
addGroupToGroup(long directoryId,
String childGroup,
String parentGroup)
Adds group as a child of the (supposedly) parent group.
|
void |
addUserToGroup(long directoryId,
String userName,
String groupName)
Adds user as a member of group.
|
boolean |
isGroupDirectMember(long directoryId,
String childGroup,
String parentGroup)
Determines whether the group is a direct member of the (supposedly) parent group.
|
boolean |
isUserDirectMember(long directoryId,
String userName,
String groupName)
Determines whether the user is a direct member of the group.
|
void |
removeGroupFromGroup(long directoryId,
String childGroup,
String parentGroup)
Removes group from the parent group.
|
void |
removeUserFromGroup(long directoryId,
String userName,
String groupName)
Removes user as a member of the given group.
|
<T> List<T> |
search(long directoryId,
MembershipQuery<T> query)
Search for memberships by the given criteria.
|
boolean isUserDirectMember(long directoryId, String userName, String groupName)
directoryId
- the directory to perform the operationuserName
- usergroupName
- groupboolean isGroupDirectMember(long directoryId, String childGroup, String parentGroup)
directoryId
- the directory to perform the operationchildGroup
- child groupparentGroup
- parent groupvoid addUserToGroup(long directoryId, String userName, String groupName) throws UserNotFoundException, GroupNotFoundException
directoryId
- the directory to perform the operationuserName
- usergroupName
- groupUserNotFoundException
- if the user does not existGroupNotFoundException
- if the group does not existBatchResult<String> addAllUsersToGroup(long directoryId, Collection<String> userNames, String groupName) throws GroupNotFoundException
directoryId
- the directory to perform the operationuserNames
- the collection of usersgroupName
- groupGroupNotFoundException
- if the group does not existvoid addGroupToGroup(long directoryId, String childGroup, String parentGroup) throws GroupNotFoundException
directoryId
- the directory to perform the operationchildGroup
- the (supposedly) child groupparentGroup
- parent groupGroupNotFoundException
- if either child or parent group is not foundvoid removeUserFromGroup(long directoryId, String userName, String groupName) throws UserNotFoundException, GroupNotFoundException, MembershipNotFoundException
directoryId
- the directory to perform the operationuserName
- usergroupName
- groupUserNotFoundException
- if the user does not existGroupNotFoundException
- if the group does not existMembershipNotFoundException
- if the user is not a member of the said groupvoid removeGroupFromGroup(long directoryId, String childGroup, String parentGroup) throws GroupNotFoundException, MembershipNotFoundException
directoryId
- the directory to perform the operationchildGroup
- child groupparentGroup
- parent groupGroupNotFoundException
- if either child or parent group does not existMembershipNotFoundException
- if the membership relationship between the child and parent group does not exist<T> List<T> search(long directoryId, MembershipQuery<T> query)
directoryId
- the directory to perform the operationquery
- criteriaCopyright © 2013 Atlassian. All Rights Reserved.