Package com.flowable.idm.engine.impl
Class AccessTokenBuilderImpl
java.lang.Object
com.flowable.idm.engine.impl.AccessTokenBuilderImpl
- All Implemented Interfaces:
AccessTokenBuilder
,Command<NewAccessToken>
public class AccessTokenBuilderImpl
extends Object
implements AccessTokenBuilder, Command<NewAccessToken>
- Author:
- Filip Hrisafov
-
Nested Class Summary
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncreate()
Create the token.description
(String description) The optional description that should be used for the token.execute
(CommandContext commandContext) The name that should be used for the token.The id of the tenant to which the token belongs.The id of the user to which the token belongs.The duration for which the token is valid.validUntil
(Instant validUntil) Until when the token is valid.
-
Field Details
-
commandExecutor
-
userId
-
tenantId
-
name
-
description
-
validFor
-
validUntil
-
-
Constructor Details
-
AccessTokenBuilderImpl
-
-
Method Details
-
userId
Description copied from interface:AccessTokenBuilder
The id of the user to which the token belongs. This can be any user which isn't part of the Identity Service.- Specified by:
userId
in interfaceAccessTokenBuilder
- Parameters:
userId
- the id of the user
-
tenantId
Description copied from interface:AccessTokenBuilder
The id of the tenant to which the token belongs.- Specified by:
tenantId
in interfaceAccessTokenBuilder
- Parameters:
tenantId
- the id of the user
-
name
Description copied from interface:AccessTokenBuilder
The name that should be used for the token.- Specified by:
name
in interfaceAccessTokenBuilder
- Parameters:
name
- the name for the token
-
description
Description copied from interface:AccessTokenBuilder
The optional description that should be used for the token.- Specified by:
description
in interfaceAccessTokenBuilder
- Parameters:
description
- the description for the token
-
validFor
Description copied from interface:AccessTokenBuilder
The duration for which the token is valid. It must be a positive duration. This is mutually exclusive withAccessTokenBuilder.validUntil(Instant)
.- Specified by:
validFor
in interfaceAccessTokenBuilder
- Parameters:
validityDuration
- the positive duration
-
validUntil
Description copied from interface:AccessTokenBuilder
Until when the token is valid. This is mutually exclusive withAccessTokenBuilder.validFor(Duration)
.- Specified by:
validUntil
in interfaceAccessTokenBuilder
- Parameters:
validUntil
- the date until the token is valid
-
create
Description copied from interface:AccessTokenBuilder
Create the token. The user visible value of the token should be retrieved throughNewAccessToken.getPlainTextValue()
.- Specified by:
create
in interfaceAccessTokenBuilder
- Returns:
- the created token
-
execute
- Specified by:
execute
in interfaceCommand<NewAccessToken>
-