Class BaseIdmIdentityServiceImpl

java.lang.Object
org.flowable.common.engine.impl.service.CommonServiceImpl<CoreIdmEngineConfiguration>
org.flowable.common.engine.impl.service.CommonEngineServiceImpl<CoreIdmEngineConfiguration>
com.flowable.idm.engine.impl.BaseIdmIdentityServiceImpl
All Implemented Interfaces:
PlatformIdentityService, org.flowable.idm.api.IdmIdentityService
Direct Known Subclasses:
IdmIdentityServiceImpl, ReadOnlyIdmIdentityService

public abstract class BaseIdmIdentityServiceImpl extends org.flowable.common.engine.impl.service.CommonEngineServiceImpl<CoreIdmEngineConfiguration> implements PlatformIdentityService
Author:
Tijs Rademakers, Filip Hrisafov
  • Constructor Details

  • Method Details

    • setUserStateAndSubState

      public void setUserStateAndSubState(String userId, String state, String subState)
      Description copied from interface: PlatformIdentityService
      Update the state and/or subState of the provided user. If the value for the state is null then the state of the user won't be changed. If the value for the subState is null then the subState of the user won't be changed. At least one of state and / or subState must be set
      Specified by:
      setUserStateAndSubState in interface PlatformIdentityService
      Parameters:
      userId - the id of the user that needs to have its state updated
      state - the optional new state to set, if null it won't be changed
      subState - the optional new subState to set, if null it won't be changed
      See Also:
    • setUserStateAndSubState

      public void setUserStateAndSubState(String userId, String state, String subState, String tenantId)
      Description copied from interface: PlatformIdentityService
      Update the state and/or subState of the provided user. If the value for the state is null then the state of the user won't be changed. If the value for the subState is null then the subState of the user won't be changed. At least one of state and / or subState must be set
      Specified by:
      setUserStateAndSubState in interface PlatformIdentityService
      Parameters:
      userId - the id of the user that needs to have its state updated
      state - the optional new state to set, if null it won't be changed
      subState - the optional new subState to set, if null it won't be changed
      tenantId - the tenant id in which the change should be done
      See Also:
    • setUserDefinitionById

      public void setUserDefinitionById(String userId, String userDefinitionId)
      Description copied from interface: PlatformIdentityService
      Update the user definition of the provided user.
      Specified by:
      setUserDefinitionById in interface PlatformIdentityService
      Parameters:
      userId - the id of the user that needs to have its user definition updated
      userDefinitionId - the user definition id of the new user definition
    • setUserDefinitionByKey

      public void setUserDefinitionByKey(String userId, String userDefinitionKey, String tenantId)
      Description copied from interface: PlatformIdentityService
      Update the user definition of the provided user.
      Specified by:
      setUserDefinitionByKey in interface PlatformIdentityService
      Parameters:
      userId - the id of the user that needs to have its user definition updated
      userDefinitionKey - the key of the new user definition
      tenantId - the tenant id of the new user definition
    • updateUserPresence

      public void updateUserPresence(String userId, String presence)
      Description copied from interface: PlatformIdentityService
      Updates the presence status of the user
      Specified by:
      updateUserPresence in interface PlatformIdentityService
      Parameters:
      userId - the id of the user for which the presence status needs to be updated
      presence - the id of the user for which the presence status needs to be updated
      See Also:
    • updateUserPresence

      public void updateUserPresence(String userId, String tenantId, String presence)
      Description copied from interface: PlatformIdentityService
      Updates the presence status of the user in the given tenant
      Specified by:
      updateUserPresence in interface PlatformIdentityService
      Parameters:
      userId - the id of the user for which the presence status needs to be updated
      tenantId - the id of tenant in which the presence status needs to be updated
      presence - the id of the user for which the presence status needs to be updated
      See Also:
    • createUserQuery

      public org.flowable.idm.api.UserQuery createUserQuery()
      Specified by:
      createUserQuery in interface org.flowable.idm.api.IdmIdentityService
    • getPlatformUserInfo

      public <T> Optional<T> getPlatformUserInfo(String userId, String name, Class<T> infoClass)
      Specified by:
      getPlatformUserInfo in interface PlatformIdentityService
    • setPlatformUserInfo

      public void setPlatformUserInfo(String userId, String name, Object value)
      Specified by:
      setPlatformUserInfo in interface PlatformIdentityService
    • createPlatformIdentityInfoBuilder

      public PlatformIdentityInfoBuilder createPlatformIdentityInfoBuilder()
      Description copied from interface: PlatformIdentityService
      Create a builder for updating or creating a platform identity info.
      Specified by:
      createPlatformIdentityInfoBuilder in interface PlatformIdentityService
    • createPlatformIdentityInfoQuery

      public PlatformIdentityInfoQuery createPlatformIdentityInfoQuery()
      Description copied from interface: PlatformIdentityService
      Create a query for querying platform identity infos.
      Specified by:
      createPlatformIdentityInfoQuery in interface PlatformIdentityService
    • createGroupQuery

      public org.flowable.idm.api.GroupQuery createGroupQuery()
      Specified by:
      createGroupQuery in interface org.flowable.idm.api.IdmIdentityService
    • setAuthenticatedUserId

      public void setAuthenticatedUserId(String authenticatedUserId)
      Specified by:
      setAuthenticatedUserId in interface org.flowable.idm.api.IdmIdentityService
    • newToken

      public org.flowable.idm.api.Token newToken(String tokenId)
      Specified by:
      newToken in interface org.flowable.idm.api.IdmIdentityService
    • saveToken

      public void saveToken(org.flowable.idm.api.Token token)
      Specified by:
      saveToken in interface org.flowable.idm.api.IdmIdentityService
    • deleteToken

      public void deleteToken(String tokenId)
      Specified by:
      deleteToken in interface org.flowable.idm.api.IdmIdentityService
    • createTokenQuery

      public org.flowable.idm.api.TokenQuery createTokenQuery()
      Specified by:
      createTokenQuery in interface org.flowable.idm.api.IdmIdentityService
    • createNativeTokenQuery

      public org.flowable.idm.api.NativeTokenQuery createNativeTokenQuery()
      Specified by:
      createNativeTokenQuery in interface org.flowable.idm.api.IdmIdentityService
    • setUserPicture

      public void setUserPicture(String userId, org.flowable.idm.api.Picture picture)
      Specified by:
      setUserPicture in interface org.flowable.idm.api.IdmIdentityService
    • getUserPicture

      public org.flowable.idm.api.Picture getUserPicture(String userId)
      Specified by:
      getUserPicture in interface org.flowable.idm.api.IdmIdentityService
    • getUserInfo

      public String getUserInfo(String userId, String key)
      Specified by:
      getUserInfo in interface org.flowable.idm.api.IdmIdentityService
    • getUserInfoKeys

      public List<String> getUserInfoKeys(String userId)
      Specified by:
      getUserInfoKeys in interface org.flowable.idm.api.IdmIdentityService
    • setUserInfo

      public void setUserInfo(String userId, String key, String value)
      Specified by:
      setUserInfo in interface org.flowable.idm.api.IdmIdentityService
    • deleteUserInfo

      public void deleteUserInfo(String userId, String key)
      Specified by:
      deleteUserInfo in interface org.flowable.idm.api.IdmIdentityService
    • createPrivilege

      public org.flowable.idm.api.Privilege createPrivilege(String name)
      Specified by:
      createPrivilege in interface org.flowable.idm.api.IdmIdentityService
    • addUserPrivilegeMapping

      public void addUserPrivilegeMapping(String privilegeId, String userId)
      Specified by:
      addUserPrivilegeMapping in interface org.flowable.idm.api.IdmIdentityService
    • deleteUserPrivilegeMapping

      public void deleteUserPrivilegeMapping(String privilegeId, String userId)
      Specified by:
      deleteUserPrivilegeMapping in interface org.flowable.idm.api.IdmIdentityService
    • addGroupPrivilegeMapping

      public void addGroupPrivilegeMapping(String privilegeId, String groupId)
      Specified by:
      addGroupPrivilegeMapping in interface org.flowable.idm.api.IdmIdentityService
    • deleteGroupPrivilegeMapping

      public void deleteGroupPrivilegeMapping(String privilegeId, String groupId)
      Specified by:
      deleteGroupPrivilegeMapping in interface org.flowable.idm.api.IdmIdentityService
    • getPrivilegeMappingsByPrivilegeId

      public List<org.flowable.idm.api.PrivilegeMapping> getPrivilegeMappingsByPrivilegeId(String privilegeId)
      Specified by:
      getPrivilegeMappingsByPrivilegeId in interface org.flowable.idm.api.IdmIdentityService
    • deletePrivilege

      public void deletePrivilege(String id)
      Specified by:
      deletePrivilege in interface org.flowable.idm.api.IdmIdentityService
    • createPrivilegeQuery

      public org.flowable.idm.api.PrivilegeQuery createPrivilegeQuery()
      Specified by:
      createPrivilegeQuery in interface org.flowable.idm.api.IdmIdentityService
    • findIdentityInfoByUserIdAndName

      public PlatformIdentityInfo findIdentityInfoByUserIdAndName(String userId, String name)
      Specified by:
      findIdentityInfoByUserIdAndName in interface PlatformIdentityService
    • deletePlatformIdentityInfoById

      public void deletePlatformIdentityInfoById(String id)
      Description copied from interface: PlatformIdentityService
      Delete the platform identity info entry for the given id
      Specified by:
      deletePlatformIdentityInfoById in interface PlatformIdentityService
      Parameters:
      id - the id of the identity info entry
    • deletePlatformIdentityInfoByUserId

      public void deletePlatformIdentityInfoByUserId(String userId)
      Description copied from interface: PlatformIdentityService
      Delete all platform identity info entries of the user
      Specified by:
      deletePlatformIdentityInfoByUserId in interface PlatformIdentityService
      Parameters:
      userId - the id of the user
    • deletePlatformIdentityInfoByUserIdAndTenantId

      public void deletePlatformIdentityInfoByUserIdAndTenantId(String userId, String tenantId)
      Description copied from interface: PlatformIdentityService
      Delete all platform identity info entries of the user in the given tenant
      Specified by:
      deletePlatformIdentityInfoByUserIdAndTenantId in interface PlatformIdentityService
      Parameters:
      userId - the id of the user
      tenantId - the id of the tenant
    • deletePlatformIdentityInfoByGroupId

      public void deletePlatformIdentityInfoByGroupId(String groupId)
      Description copied from interface: PlatformIdentityService
      Delete all platform identity info entries of the group
      Specified by:
      deletePlatformIdentityInfoByGroupId in interface PlatformIdentityService
      Parameters:
      groupId - the id of the group
    • deletePlatformIdentityInfoByGroupIdAndTenantId

      public void deletePlatformIdentityInfoByGroupIdAndTenantId(String groupId, String tenantId)
      Description copied from interface: PlatformIdentityService
      Delete all platform identity info entries of the group in the given tenant
      Specified by:
      deletePlatformIdentityInfoByGroupIdAndTenantId in interface PlatformIdentityService
      Parameters:
      groupId - the id of the group
      tenantId - the id of the tenant
    • createAuthenticationTokenBuilder

      @Deprecated public TokenAuthenticationBuilder createAuthenticationTokenBuilder()
      Deprecated.
      Description copied from interface: PlatformIdentityService
      Create a token authentication builder with which authentication tokens can be created.
      Specified by:
      createAuthenticationTokenBuilder in interface PlatformIdentityService
      Returns:
      the token authentication builder
    • findPropertyByName

      public IdmProperty findPropertyByName(String name)
      Specified by:
      findPropertyByName in interface PlatformIdentityService
    • updateProperty

      public void updateProperty(IdmProperty idmProperty)
      Specified by:
      updateProperty in interface PlatformIdentityService
    • createProperty

      public IdmProperty createProperty(String name, String value)
      Specified by:
      createProperty in interface PlatformIdentityService
    • deleteProperty

      public void deleteProperty(String name)
      Specified by:
      deleteProperty in interface PlatformIdentityService
    • createNewAccessTokenBuilder

      public AccessTokenBuilder createNewAccessTokenBuilder()
      Specified by:
      createNewAccessTokenBuilder in interface PlatformIdentityService
    • createAccessTokenQuery

      public AccessTokenQuery createAccessTokenQuery()
      Specified by:
      createAccessTokenQuery in interface PlatformIdentityService
    • findAccessToken

      public AccessToken findAccessToken(String tokenId)
      Specified by:
      findAccessToken in interface PlatformIdentityService
    • checkAccessToken

      public boolean checkAccessToken(String tokenId, String tokenValue)
      Description copied from interface: PlatformIdentityService
      Check if the access token with the given id is valid for the given value
      Specified by:
      checkAccessToken in interface PlatformIdentityService
      Parameters:
      tokenId - the id of the token to check
      tokenValue - the value that should be checked
    • deleteAccessToken

      public void deleteAccessToken(String tokenId)
      Specified by:
      deleteAccessToken in interface PlatformIdentityService