Interface ExternalIdentityMappingService
-
- All Known Implementing Classes:
ExternalIdentityMappingServiceImpl
public interface ExternalIdentityMappingService- Since:
- 6.0
- Author:
- Emmanuel Duchastenier, Celine Souchet
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description SExternalIdentityMappingcreateExternalIdentityMapping(SExternalIdentityMapping externalIdentityMapping)Create externalIdentityMapping in DB for given externalIdentityMappingvoiddeleteAllExternalIdentityMappings()Delete all external identity mapping for the connected tenantvoiddeleteExternalIdentityMapping(long mappingId)Delete the id specified externalIdentityMappingvoiddeleteExternalIdentityMapping(SExternalIdentityMapping externalIdentityMapping)Delete the specific externalIdentityMappingSExternalIdentityMappinggetExternalIdentityMappingById(long mappingId)Get externalIdentityMapping by its idSExternalIdentityMappinggetExternalIdentityMappingById(long mappingId, java.lang.String suffix, java.lang.String messageSuffix)SExternalIdentityMappinggetExternalIdentityMappingForGroup(long mappingId)Get externalIdentityMapping by its id with displayNamePart having group related informationsSExternalIdentityMappinggetExternalIdentityMappingForRole(long mappingId)Get externalIdentityMapping by its id with displayNamePart having role related informationsSExternalIdentityMappinggetExternalIdentityMappingForRoleAndGroup(long mappingId)Get externalIdentityMapping by its id with displayNamePart having role and group related informationsSExternalIdentityMappinggetExternalIdentityMappingForUser(long mappingId)Get externalIdentityMapping by its id with displayNamePart having user related informationslonggetNumberOfExternalIdentityMappings(java.lang.String kind, QueryOptions searchOptions, java.lang.String querySuffix)Get total number of externalIdentityMappings for specific kind according to the queryOptions.longgetNumberOfExternalIdentityMappingsForUser(java.lang.String kind, long userId, java.lang.String externalId, QueryOptions searchOptions, java.lang.String querySuffix)Get total number ofSExternalIdentityMappingobjects associated with the specified externalId and kind for the specific user.java.util.List<SExternalIdentityMapping>searchExternalIdentityMappings(java.lang.String kind, java.lang.String externalId, QueryOptions queryOptions)Search allSExternalIdentityMappingobjects associated with the specified externalId and kind.java.util.List<SExternalIdentityMapping>searchExternalIdentityMappings(java.lang.String kind, QueryOptions queryOptions, java.lang.String querySuffix)Get all externalIdentityMappings for specific kind according to the queryOptions.java.util.List<SExternalIdentityMapping>searchExternalIdentityMappingsForUser(java.lang.String kind, long userId, java.lang.String externalId, QueryOptions queryOptions, java.lang.String querySuffix)Search allSExternalIdentityMappingobjects associated with the specified externalId and kind for the specific user.
-
-
-
Method Detail
-
createExternalIdentityMapping
SExternalIdentityMapping createExternalIdentityMapping(SExternalIdentityMapping externalIdentityMapping) throws SExternalIdentityMappingAlreadyExistsException, SExternalIdentityMappingCreationException
Create externalIdentityMapping in DB for given externalIdentityMapping- Parameters:
externalIdentityMapping- an SExternalIdentityMapping object will be stored in DB- Returns:
- the new created SExternalIdentityMapping object
- Throws:
SExternalIdentityMappingAlreadyExistsException- error thrown if externalIdentityMapping already exists in DBSExternalIdentityMappingCreationException
-
getExternalIdentityMappingById
SExternalIdentityMapping getExternalIdentityMappingById(long mappingId) throws SExternalIdentityMappingNotFoundException
Get externalIdentityMapping by its id- Parameters:
mappingId- the identifier of externalIdentityMapping- Returns:
- the externalIdentityMapping have id corresponding to the parameter
- Throws:
SExternalIdentityMappingNotFoundException- error thrown if no externalIdentityMapping have an id corresponding to the parameter.
-
getExternalIdentityMappingForUser
SExternalIdentityMapping getExternalIdentityMappingForUser(long mappingId) throws SExternalIdentityMappingNotFoundException
Get externalIdentityMapping by its id with displayNamePart having user related informations- Parameters:
mappingId- the identifier of externalIdentityMapping- Returns:
- the externalIdentityMapping with displayNamePart having userName informations
- Throws:
SExternalIdentityMappingNotFoundException- error thrown if no externalIdentityMapping have an id corresponding to the parameter.
-
getExternalIdentityMappingForGroup
SExternalIdentityMapping getExternalIdentityMappingForGroup(long mappingId) throws SExternalIdentityMappingNotFoundException
Get externalIdentityMapping by its id with displayNamePart having group related informations- Parameters:
mappingId- the identifier of externalIdentityMapping- Returns:
- the externalIdentityMapping with displayNamePart having group related informations
- Throws:
SExternalIdentityMappingNotFoundException- error thrown if no externalIdentityMapping have an id corresponding to the parameter.
-
getExternalIdentityMappingForRole
SExternalIdentityMapping getExternalIdentityMappingForRole(long mappingId) throws SExternalIdentityMappingNotFoundException
Get externalIdentityMapping by its id with displayNamePart having role related informations- Parameters:
mappingId- the identifier of externalIdentityMapping- Returns:
- the externalIdentityMapping with displayNamePart having role related informations
- Throws:
SExternalIdentityMappingNotFoundException- error thrown if no externalIdentityMapping have an id corresponding to the parameter.
-
getExternalIdentityMappingForRoleAndGroup
SExternalIdentityMapping getExternalIdentityMappingForRoleAndGroup(long mappingId) throws SExternalIdentityMappingNotFoundException
Get externalIdentityMapping by its id with displayNamePart having role and group related informations- Parameters:
mappingId- the identifier of externalIdentityMapping- Returns:
- the externalIdentityMapping with displayNamePart having role and group related informations
- Throws:
SExternalIdentityMappingNotFoundException- error thrown if no externalIdentityMapping have an id corresponding to the parameter.
-
deleteExternalIdentityMapping
void deleteExternalIdentityMapping(long mappingId) throws SExternalIdentityMappingNotFoundException, SExternalIdentityMappingDeletionExceptionDelete the id specified externalIdentityMapping- Parameters:
mappingId- the identifier of externalIdentityMapping- Throws:
SExternalIdentityMappingNotFoundException- error thrown if no externalIdentityMapping have an id corresponding to the parameter.SExternalIdentityMappingDeletionException
-
deleteExternalIdentityMapping
void deleteExternalIdentityMapping(SExternalIdentityMapping externalIdentityMapping) throws SExternalIdentityMappingDeletionException
Delete the specific externalIdentityMapping- Parameters:
externalIdentityMapping- the externalIdentityMapping will be deleted- Throws:
SExternalIdentityMappingDeletionException
-
deleteAllExternalIdentityMappings
void deleteAllExternalIdentityMappings() throws SExternalIdentityMappingDeletionExceptionDelete all external identity mapping for the connected tenant- Throws:
SExternalIdentityMappingDeletionException- Since:
- 6.1
-
searchExternalIdentityMappings
java.util.List<SExternalIdentityMapping> searchExternalIdentityMappings(java.lang.String kind, QueryOptions queryOptions, java.lang.String querySuffix) throws SBonitaReadException
Get all externalIdentityMappings for specific kind according to the queryOptions. use querySuffix to indicate what the displayNamePart is related to- Parameters:
kind- the discriminator of theSExternalIdentityMappingto search for.queryOptions- a QueryOptions object containing some query conditionsquerySuffix- The query suffix, it can be "USER", "GROUP", "ROLE", "MEMBERSHIP";- Returns:
- a list of SExternalIdentityMapping objects matching the criteria.
- Throws:
SBonitaReadException
-
getNumberOfExternalIdentityMappings
long getNumberOfExternalIdentityMappings(java.lang.String kind, QueryOptions searchOptions, java.lang.String querySuffix) throws SBonitaReadExceptionGet total number of externalIdentityMappings for specific kind according to the queryOptions.- Parameters:
kind- the discriminator of theSExternalIdentityMappingto search for.searchOptions- a QueryOptions object containing some query conditionsquerySuffix- the query suffix, it can be "USER", "GROUP", "ROLE", "MEMBERSHIP";- Returns:
- number of externalIdentityMappings matching the criteria.
- Throws:
SBonitaReadException
-
searchExternalIdentityMappingsForUser
java.util.List<SExternalIdentityMapping> searchExternalIdentityMappingsForUser(java.lang.String kind, long userId, java.lang.String externalId, QueryOptions queryOptions, java.lang.String querySuffix) throws SBonitaReadException
Search allSExternalIdentityMappingobjects associated with the specified externalId and kind for the specific user. Use querySuffix to indicate what the displayNamePart is related to- Parameters:
kind- the discriminator of theSExternalIdentityMappingto search for.userId- The identifier of userexternalId- the external Id identifying theSExternalIdentityMappings to search.queryOptions- a QueryOptions object containing some query conditionsquerySuffix- the query suffix, it can be "USER", "GROUP", "ROLE", "MEMBERSHIP";- Returns:
- the list of results matching the criteria.
- Throws:
SBonitaReadException
-
getNumberOfExternalIdentityMappingsForUser
long getNumberOfExternalIdentityMappingsForUser(java.lang.String kind, long userId, java.lang.String externalId, QueryOptions searchOptions, java.lang.String querySuffix) throws SBonitaReadExceptionGet total number ofSExternalIdentityMappingobjects associated with the specified externalId and kind for the specific user. Use querySuffix to indicate what the displayNamePart is related to- Parameters:
kind- the discriminator of theSExternalIdentityMappingto search for.userId- The identifier of userexternalId- the external Id identifying theSExternalIdentityMappings to search.searchOptions- a QueryOptions object containing some query conditionsquerySuffix- the query suffix, it can be "USER", "GROUP", "ROLE", "MEMBERSHIP";- Returns:
- the number of externalIdentityMappings matching the criteria.
- Throws:
SBonitaReadException
-
searchExternalIdentityMappings
java.util.List<SExternalIdentityMapping> searchExternalIdentityMappings(java.lang.String kind, java.lang.String externalId, QueryOptions queryOptions) throws SBonitaReadException
Search allSExternalIdentityMappingobjects associated with the specified externalId and kind.- Parameters:
kind- the discriminator of theSExternalIdentityMappingto search for.externalId- the external Id identifying theSExternalIdentityMappings to search.queryOptions- a QueryOptions object containing some query conditions- Returns:
- the list of results matching the criteria.
- Throws:
SBonitaReadException- in case of search error.
-
getExternalIdentityMappingById
SExternalIdentityMapping getExternalIdentityMappingById(long mappingId, java.lang.String suffix, java.lang.String messageSuffix) throws SExternalIdentityMappingNotFoundException
- Parameters:
mappingId-suffix- the query suffix to specify (ForUser, ForGroup, ...)messageSuffix-- Returns:
- Throws:
SExternalIdentityMappingNotFoundException
-
-