Class CrowdServiceImpl
java.lang.Object
com.atlassian.crowd.embedded.core.CrowdServiceImpl
- All Implemented Interfaces:
CrowdService,UnfilteredCrowdService
Default implementation of the CrowdService
-
Constructor Summary
ConstructorsConstructorDescriptionCrowdServiceImpl(ApplicationFactory applicationFactory, ApplicationService applicationService, DirectoryInstanceLoader directoryInstanceLoader) -
Method Summary
Modifier and TypeMethodDescriptionbooleanaddGroupToGroup(Group childGroup, Group parentGroup) addUser(UserWithAttributes user, String credential) booleanaddUserToGroup(User user, Group group) authenticate(String name, String credential) getGroupWithAttributes(String name) getRemoteUser(String username) getUserWithAttributes(String name) booleanisGroupDirectGroupMember(Group childGroup, Group parentGroup) booleanisGroupMemberOfGroup(Group childGroup, Group parentGroup) booleanisGroupMemberOfGroup(String childGroupName, String parentGroupName) booleanisUserDirectGroupMember(User user, Group group) booleanisUserMemberOfGroup(User user, Group group) booleanisUserMemberOfGroup(String userName, String groupName) voidremoveAllGroupAttributes(Group group) voidremoveAllUserAttributes(User user) booleanremoveGroup(Group group) voidremoveGroupAttribute(Group group, String attributeName) booleanremoveGroupFromGroup(Group childGroup, Group parentGroup) booleanremoveUser(User user) voidremoveUserAttribute(User user, String attributeName) booleanremoveUserFromGroup(User user, Group group) renameUser(User user, String newUsername) <T> Iterable<T>voidsetGroupAttribute(Group group, String attributeName, String attributeValue) voidsetGroupAttribute(Group group, String attributeName, Set<String> attributeValues) voidsetUserAttribute(User user, String attributeName, String attributeValue) voidsetUserAttribute(User user, String attributeName, Set<String> attributeValues) updateGroup(Group group) updateUser(User user) voidupdateUserCredential(User user, String credential) userAuthenticated(String username)
-
Constructor Details
-
CrowdServiceImpl
public CrowdServiceImpl(ApplicationFactory applicationFactory, ApplicationService applicationService, DirectoryInstanceLoader directoryInstanceLoader)
-
-
Method Details
-
authenticate
public User authenticate(String name, String credential) throws FailedAuthenticationException, OperationFailedException - Specified by:
authenticatein interfaceCrowdService- Throws:
FailedAuthenticationExceptionOperationFailedException
-
getUser
- Specified by:
getUserin interfaceCrowdService
-
getRemoteUser
- Specified by:
getRemoteUserin interfaceCrowdService
-
userAuthenticated
public User userAuthenticated(String username) throws UserNotFoundException, OperationFailedException, InactiveAccountException - Specified by:
userAuthenticatedin interfaceCrowdService- Throws:
UserNotFoundExceptionOperationFailedExceptionInactiveAccountException
-
getUserWithAttributes
- Specified by:
getUserWithAttributesin interfaceCrowdService
-
getGroup
- Specified by:
getGroupin interfaceCrowdService
-
getGroupWithAttributes
- Specified by:
getGroupWithAttributesin interfaceCrowdService
-
search
- Specified by:
searchin interfaceCrowdService
-
isUserMemberOfGroup
- Specified by:
isUserMemberOfGroupin interfaceCrowdService
-
isUserMemberOfGroup
- Specified by:
isUserMemberOfGroupin interfaceCrowdService
-
isGroupMemberOfGroup
- Specified by:
isGroupMemberOfGroupin interfaceCrowdService
-
isGroupMemberOfGroup
- Specified by:
isGroupMemberOfGroupin interfaceCrowdService
-
addUser
public User addUser(User user, String credential) throws InvalidUserException, InvalidCredentialException, OperationNotPermittedException, OperationFailedException - Specified by:
addUserin interfaceCrowdService- Throws:
InvalidUserExceptionInvalidCredentialExceptionOperationNotPermittedExceptionOperationFailedException
-
addUser
public UserWithAttributes addUser(UserWithAttributes user, String credential) throws InvalidUserException, InvalidCredentialException, OperationNotPermittedException, OperationFailedException - Specified by:
addUserin interfaceCrowdService- Throws:
InvalidUserExceptionInvalidCredentialExceptionOperationNotPermittedExceptionOperationFailedException
-
updateUser
public User updateUser(User user) throws UserNotFoundException, InvalidUserException, OperationNotPermittedException, OperationFailedException - Specified by:
updateUserin interfaceCrowdService- Throws:
UserNotFoundExceptionInvalidUserExceptionOperationNotPermittedExceptionOperationFailedException
-
renameUser
public User renameUser(User user, String newUsername) throws UserNotFoundException, InvalidUserException, OperationNotPermittedException, OperationFailedException - Specified by:
renameUserin interfaceCrowdService- Throws:
UserNotFoundExceptionInvalidUserExceptionOperationNotPermittedExceptionOperationFailedException
-
updateUserCredential
public void updateUserCredential(User user, String credential) throws UserNotFoundException, InvalidCredentialException, OperationNotPermittedException, OperationFailedException - Specified by:
updateUserCredentialin interfaceCrowdService- Throws:
UserNotFoundExceptionInvalidCredentialExceptionOperationNotPermittedExceptionOperationFailedException
-
setUserAttribute
public void setUserAttribute(User user, String attributeName, String attributeValue) throws UserNotFoundException, OperationNotPermittedException, OperationFailedException - Specified by:
setUserAttributein interfaceCrowdService- Throws:
UserNotFoundExceptionOperationNotPermittedExceptionOperationFailedException
-
setUserAttribute
public void setUserAttribute(User user, String attributeName, Set<String> attributeValues) throws UserNotFoundException, OperationNotPermittedException, OperationFailedException - Specified by:
setUserAttributein interfaceCrowdService- Throws:
UserNotFoundExceptionOperationNotPermittedExceptionOperationFailedException
-
removeUserAttribute
public void removeUserAttribute(User user, String attributeName) throws UserNotFoundException, OperationNotPermittedException, OperationFailedException - Specified by:
removeUserAttributein interfaceCrowdService- Throws:
UserNotFoundExceptionOperationNotPermittedExceptionOperationFailedException
-
removeAllUserAttributes
public void removeAllUserAttributes(User user) throws UserNotFoundException, OperationNotPermittedException, OperationFailedException - Specified by:
removeAllUserAttributesin interfaceCrowdService- Throws:
UserNotFoundExceptionOperationNotPermittedExceptionOperationFailedException
-
removeUser
public boolean removeUser(User user) throws OperationNotPermittedException, OperationFailedException - Specified by:
removeUserin interfaceCrowdService- Throws:
OperationNotPermittedExceptionOperationFailedException
-
addGroup
public Group addGroup(Group group) throws InvalidGroupException, OperationNotPermittedException, OperationFailedException - Specified by:
addGroupin interfaceCrowdService- Throws:
InvalidGroupExceptionOperationNotPermittedExceptionOperationFailedException
-
updateGroup
public Group updateGroup(Group group) throws InvalidGroupException, OperationNotPermittedException, GroupNotFoundException, OperationFailedException - Specified by:
updateGroupin interfaceCrowdService- Throws:
InvalidGroupExceptionOperationNotPermittedExceptionGroupNotFoundExceptionOperationFailedException
-
setGroupAttribute
public void setGroupAttribute(Group group, String attributeName, String attributeValue) throws GroupNotFoundException, OperationNotPermittedException, OperationFailedException - Specified by:
setGroupAttributein interfaceCrowdService- Throws:
GroupNotFoundExceptionOperationNotPermittedExceptionOperationFailedException
-
setGroupAttribute
public void setGroupAttribute(Group group, String attributeName, Set<String> attributeValues) throws GroupNotFoundException, OperationNotPermittedException, OperationFailedException - Specified by:
setGroupAttributein interfaceCrowdService- Throws:
GroupNotFoundExceptionOperationNotPermittedExceptionOperationFailedException
-
removeGroupAttribute
public void removeGroupAttribute(Group group, String attributeName) throws GroupNotFoundException, OperationNotPermittedException, OperationFailedException - Specified by:
removeGroupAttributein interfaceCrowdService- Throws:
GroupNotFoundExceptionOperationNotPermittedExceptionOperationFailedException
-
removeAllGroupAttributes
public void removeAllGroupAttributes(Group group) throws GroupNotFoundException, OperationNotPermittedException, OperationFailedException - Specified by:
removeAllGroupAttributesin interfaceCrowdService- Throws:
GroupNotFoundExceptionOperationNotPermittedExceptionOperationFailedException
-
removeGroup
public boolean removeGroup(Group group) throws OperationNotPermittedException, GroupNotFoundException, OperationFailedException - Specified by:
removeGroupin interfaceCrowdService- Throws:
OperationNotPermittedExceptionGroupNotFoundExceptionOperationFailedException
-
addUserToGroup
public boolean addUserToGroup(User user, Group group) throws GroupNotFoundException, UserNotFoundException, OperationNotPermittedException, OperationFailedException - Specified by:
addUserToGroupin interfaceCrowdService- Throws:
GroupNotFoundExceptionUserNotFoundExceptionOperationNotPermittedExceptionOperationFailedException
-
addGroupToGroup
public boolean addGroupToGroup(Group childGroup, Group parentGroup) throws GroupNotFoundException, OperationNotPermittedException, InvalidMembershipException, OperationFailedException - Specified by:
addGroupToGroupin interfaceCrowdService- Throws:
GroupNotFoundExceptionOperationNotPermittedExceptionInvalidMembershipExceptionOperationFailedException
-
removeUserFromGroup
public boolean removeUserFromGroup(User user, Group group) throws GroupNotFoundException, UserNotFoundException, OperationNotPermittedException, MembershipNotFoundException, OperationFailedException - Specified by:
removeUserFromGroupin interfaceCrowdService- Throws:
GroupNotFoundExceptionUserNotFoundExceptionOperationNotPermittedExceptionMembershipNotFoundExceptionOperationFailedException
-
removeGroupFromGroup
public boolean removeGroupFromGroup(Group childGroup, Group parentGroup) throws GroupNotFoundException, OperationNotPermittedException, MembershipNotFoundException, OperationFailedException - Specified by:
removeGroupFromGroupin interfaceCrowdService- Throws:
GroupNotFoundExceptionOperationNotPermittedExceptionMembershipNotFoundExceptionOperationFailedException
-
isUserDirectGroupMember
- Specified by:
isUserDirectGroupMemberin interfaceCrowdService- Throws:
OperationFailedException
-
isGroupDirectGroupMember
public boolean isGroupDirectGroupMember(Group childGroup, Group parentGroup) throws OperationFailedException - Specified by:
isGroupDirectGroupMemberin interfaceCrowdService- Throws:
OperationFailedException
-
getCapabilitiesForNewUsers
- Specified by:
getCapabilitiesForNewUsersin interfaceCrowdService
-