@Transactional(propagation=REQUIRED) public abstract class UserGroupManagementBase extends Object implements UserGroupManagement
Spring Service base class for UserGroupManagement, provides access to all services
and entities referenced by this service.
UserGroupManagement| Constructor and Description |
|---|
UserGroupManagementBase() |
| Modifier and Type | Method and Description |
|---|---|
Long |
createExternalGroup(ExternalGroupVO groupVO)
Create a group imported from an external system.
|
Group |
createGroup(GroupVO groupVO)
Create a new group.
|
Long |
createOrUpdateExternalGroup(ExternalGroupVO groupVO)
Create a group imported from an external system or if that group already exists it is
updated.
|
void |
deleteExternalGroup(Long groupId,
String externalSystemId)
Delete an external group.
|
void |
deleteGroup(Long groupId)
Delete a group.
|
<T> T |
findGroupByAlias(String alias,
Converter<Group,T> converter)
Find a user group by its alias and convert it to the object to be returned.
|
<T> T |
findGroupById(Long id,
Converter<Group,T> converter)
Find a user group by its ID and convert it to the object to be returned.
|
protected abstract Long |
handleCreateExternalGroup(ExternalGroupVO groupVO)
Performs the core logic for
createExternalGroup(ExternalGroupVO) |
protected abstract Group |
handleCreateGroup(GroupVO groupVO)
Performs the core logic for
createGroup(GroupVO) |
protected abstract Long |
handleCreateOrUpdateExternalGroup(ExternalGroupVO groupVO)
Performs the core logic for
createOrUpdateExternalGroup(ExternalGroupVO) |
protected abstract void |
handleDeleteExternalGroup(Long groupId,
String externalSystemId)
Performs the core logic for
deleteExternalGroup(Long, String) |
protected abstract void |
handleDeleteGroup(Long groupId)
Performs the core logic for
deleteGroup(Long) |
protected abstract <T> T |
handleFindGroupByAlias(String alias,
Converter<Group,T> converter)
Find a user group by its alias and convert it to the object to be returned.
|
protected abstract <T> T |
handleFindGroupById(Long id,
Converter<Group,T> converter)
Find a user group by its ID and convert it to the object to be returned.
|
protected abstract boolean |
handleIsExternalGroup(Long groupId)
Test whether a group is an external group or an internal group.
|
protected abstract void |
handleUpdateExternalGroup(Long groupId,
ExternalGroupVO groupVO)
Performs the core logic for
#updateExternalGroup(ExternalGroupVO) |
protected abstract void |
handleUpdateGroup(Long groupId,
GroupVO groupVO)
Performs the core logic for
updateGroup(Long, GroupVO) |
boolean |
isExternalGroup(Long groupId)
Test whether a group is an external group or an internal group.
|
void |
updateExternalGroup(Long groupId,
ExternalGroupVO groupVO)
Update a group that was imported from an external system.
|
void |
updateGroup(Long groupId,
GroupVO groupVO)
Update an existing group.
|
public Long createExternalGroup(ExternalGroupVO groupVO) throws AliasValidationException, AliasAlreadyExistsException, GroupAlreadyExistsException
UserGroupManagementCreate a group imported from an external system.
createExternalGroup in interface UserGroupManagementgroupVO - a value object with details about the group. If the alias member is not set it
will be generated from the name.AliasValidationException - in case the alias field is not validAliasAlreadyExistsException - in case the alias already existsGroupAlreadyExistsException - in case there is already a local group for the external grouppublic Group createGroup(GroupVO groupVO) throws AliasAlreadyExistsException, AliasValidationException, AuthorizationException
UserGroupManagementcreateGroup in interface UserGroupManagementAuthorizationException - in case the current user is not the client manager or the internal system userAliasAlreadyExistsExceptionAliasValidationExceptionpublic Long createOrUpdateExternalGroup(ExternalGroupVO groupVO) throws AliasValidationException, AliasAlreadyExistsException
UserGroupManagementCreate a group imported from an external system or if that group already exists it is updated.
createOrUpdateExternalGroup in interface UserGroupManagementgroupVO - a value object with details about the group. If the alias member is not set it
will be generated from the name.AliasValidationException - in case the alias field is not validAliasAlreadyExistsException - in case the alias already existspublic void deleteExternalGroup(Long groupId, String externalSystemId) throws AuthorizationException
UserGroupManagementdeleteExternalGroup in interface UserGroupManagementAuthorizationException - in case the current user is not the internal system userpublic void deleteGroup(Long groupId) throws AuthorizationException
UserGroupManagementdeleteGroup in interface UserGroupManagementgroupId - the Id of the group to deleteGroupOperationNotPermittedException - if the group refers to an external groupAuthorizationException - if the current user is not client manager@Transactional(readOnly=true) public <T> T findGroupByAlias(String alias, Converter<Group,T> converter)
UserGroupManagementfindGroupByAlias in interface UserGroupManagementT - the type of the target objectalias - the alias of the group to retrieveconverter - the converter to create the target object@Transactional(readOnly=true) public <T> T findGroupById(Long id, Converter<Group,T> converter)
UserGroupManagementfindGroupById in interface UserGroupManagementT - the type of the target objectid - the ID of the group to retrieveconverter - the converter to create the target objectprotected abstract Long handleCreateExternalGroup(ExternalGroupVO groupVO) throws AliasValidationException, AliasAlreadyExistsException, GroupAlreadyExistsException
createExternalGroup(ExternalGroupVO)protected abstract Group handleCreateGroup(GroupVO groupVO) throws AliasAlreadyExistsException, AliasValidationException, AuthorizationException
createGroup(GroupVO)protected abstract Long handleCreateOrUpdateExternalGroup(ExternalGroupVO groupVO) throws AliasAlreadyExistsException, AliasValidationException
createOrUpdateExternalGroup(ExternalGroupVO)groupVO - a value object with details about the group. If the alias member is not set it
will be generated from the name.AliasValidationException - in case the alias field is not validAliasAlreadyExistsException - in case the alias already existsprotected abstract void handleDeleteExternalGroup(Long groupId, String externalSystemId) throws AuthorizationException
deleteExternalGroup(Long, String)AuthorizationExceptionprotected abstract void handleDeleteGroup(Long groupId) throws GroupOperationNotPermittedException, AuthorizationException
deleteGroup(Long)protected abstract <T> T handleFindGroupByAlias(String alias, Converter<Group,T> converter)
T - the type of the target objectalias - the alias of the group to retrieveconverter - the converter to create the target objectprotected abstract <T> T handleFindGroupById(Long id, Converter<Group,T> converter)
T - the type of the target objectid - the ID of the group to retrieveconverter - the converter to create the target objectprotected abstract boolean handleIsExternalGroup(Long groupId)
groupId - the ID of the group to testprotected abstract void handleUpdateExternalGroup(Long groupId, ExternalGroupVO groupVO) throws GroupNotFoundException
#updateExternalGroup(ExternalGroupVO)groupId - the ID of the groupgroupVO - a value object with details about the group.GroupNotFoundException - in case the group to update does not existprotected abstract void handleUpdateGroup(Long groupId, GroupVO groupVO) throws GroupNotFoundException, GroupOperationNotPermittedException
updateGroup(Long, GroupVO)@Transactional(readOnly=true) public boolean isExternalGroup(Long groupId)
UserGroupManagementisExternalGroup in interface UserGroupManagementgroupId - the ID of the group to testpublic void updateExternalGroup(Long groupId, ExternalGroupVO groupVO) throws GroupNotFoundException
UserGroupManagementupdateExternalGroup in interface UserGroupManagementgroupId - ID of the group to updategroupVO - a value object with details about the groupGroupNotFoundException - in case the group to update does not existpublic void updateGroup(Long groupId, GroupVO groupVO) throws GroupNotFoundException, GroupOperationNotPermittedException
UserGroupManagementUpdate an existing group. The alias won't be changed.
updateGroup in interface UserGroupManagementgroupId - the ID of the group to updategroupVO - a value object with details about the groupGroupNotFoundException - in case the group to update does not existGroupOperationNotPermittedExceptionCopyright © 2019 Communote team. All rights reserved.