Package com.flowable.idm.engine.impl
Class UserAccountBuilderImpl
- java.lang.Object
-
- com.flowable.idm.engine.impl.UserAccountBuilderImpl
-
- All Implemented Interfaces:
UserAccountBuilder
public class UserAccountBuilderImpl extends java.lang.Object implements UserAccountBuilder
- Author:
- Filip Hrisafov
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.String
accountId
protected java.lang.String
businessAccountId
protected java.lang.String
externalUserId
protected CoreIdmEngineConfiguration
idmEngineConfiguration
protected java.util.Set<java.lang.String>
modifiedProperties
protected java.lang.String
name
protected java.lang.String
state
protected java.lang.String
subState
protected java.lang.String
subType
protected java.lang.String
tenantId
protected java.lang.String
type
protected java.lang.String
userAccountDefinitionId
protected java.lang.String
userAccountDefinitionKey
protected java.lang.String
userId
-
Constructor Summary
Constructors Constructor Description UserAccountBuilderImpl(CoreIdmEngineConfiguration idmEngineConfiguration, java.lang.String accountId)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description UserAccountBuilder
businessAccountId(java.lang.String businessAccountId)
The id of the business account that the user account would be linked to (e.g.UserAccountBuilder
externalUserId(java.lang.String externalUserId)
The id of the user within the external system (e.g.java.lang.String
getBusinessAccountId()
java.lang.String
getExternalUserId()
java.lang.String
getName()
java.lang.String
getState()
java.lang.String
getSubState()
java.lang.String
getSubType()
java.lang.String
getTenantId()
java.lang.String
getType()
java.lang.String
getUserAccountDefinitionId()
java.lang.String
getUserAccountDefinitionKey()
java.lang.String
getUserId()
boolean
isPropertyModified(java.lang.String property)
UserAccountBuilder
name(java.lang.String name)
The name of the account (e.g.UserAccount
save()
Performs the save of the user accountUserAccountBuilder
state(java.lang.String state)
The initial state of the created account.UserAccountBuilder
subState(java.lang.String subState)
The initial sub state of the created account.UserAccountBuilder
subType(java.lang.String subType)
The sub type of the account.UserAccountBuilder
tenantId(java.lang.String tenantId)
The id of the tenant that this account belongs toUserAccountBuilder
type(java.lang.String type)
Set the type of the account.UserAccountBuilder
userAccountDefinitionId(java.lang.String userAccountDefinitionId)
The id of theUserAccountDefinition
that should be used when creating the user account.UserAccountBuilder
userAccountDefinitionKey(java.lang.String userAccountDefinitionKey)
The key of theUserAccountDefinition
that should be used when creating the user account.UserAccountBuilder
userId(java.lang.String userId)
The id of the user that this account belongs to
-
-
-
Field Detail
-
idmEngineConfiguration
protected final CoreIdmEngineConfiguration idmEngineConfiguration
-
accountId
protected final java.lang.String accountId
-
userId
protected java.lang.String userId
-
tenantId
protected java.lang.String tenantId
-
name
protected java.lang.String name
-
type
protected java.lang.String type
-
subType
protected java.lang.String subType
-
state
protected java.lang.String state
-
subState
protected java.lang.String subState
-
businessAccountId
protected java.lang.String businessAccountId
-
externalUserId
protected java.lang.String externalUserId
-
userAccountDefinitionId
protected java.lang.String userAccountDefinitionId
-
userAccountDefinitionKey
protected java.lang.String userAccountDefinitionKey
-
modifiedProperties
protected java.util.Set<java.lang.String> modifiedProperties
-
-
Constructor Detail
-
UserAccountBuilderImpl
public UserAccountBuilderImpl(CoreIdmEngineConfiguration idmEngineConfiguration, java.lang.String accountId)
-
-
Method Detail
-
userId
public UserAccountBuilder userId(java.lang.String userId)
Description copied from interface:UserAccountBuilder
The id of the user that this account belongs to- Specified by:
userId
in interfaceUserAccountBuilder
- Parameters:
userId
- the user id linked with the account
-
tenantId
public UserAccountBuilder tenantId(java.lang.String tenantId)
Description copied from interface:UserAccountBuilder
The id of the tenant that this account belongs to- Specified by:
tenantId
in interfaceUserAccountBuilder
- Parameters:
tenantId
- the tenant id for the account
-
name
public UserAccountBuilder name(java.lang.String name)
Description copied from interface:UserAccountBuilder
The name of the account (e.g. WhatsApp for XY, etc)- Specified by:
name
in interfaceUserAccountBuilder
- Parameters:
name
- the name for the account
-
type
public UserAccountBuilder type(java.lang.String type)
Description copied from interface:UserAccountBuilder
Set the type of the account. (e.g. Messenger)- Specified by:
type
in interfaceUserAccountBuilder
- Parameters:
type
- the type of the account- See Also:
for known types
-
subType
public UserAccountBuilder subType(java.lang.String subType)
Description copied from interface:UserAccountBuilder
The sub type of the account. (e.g. WhatsApp, WeChat, Facebook, etc)- Specified by:
subType
in interfaceUserAccountBuilder
- Parameters:
subType
- the sub type of the account- See Also:
for known sub types
-
state
public UserAccountBuilder state(java.lang.String state)
Description copied from interface:UserAccountBuilder
The initial state of the created account. In order to update the state of the account theUserAccountService.setStateAndSubState(String, String, String)
should be used.- Specified by:
state
in interfaceUserAccountBuilder
- Parameters:
state
- the initial state for the created account
-
subState
public UserAccountBuilder subState(java.lang.String subState)
Description copied from interface:UserAccountBuilder
The initial sub state of the created account. In order to update the state of the account theUserAccountService.setStateAndSubState(String, String, String)
should be used.- Specified by:
subState
in interfaceUserAccountBuilder
- Parameters:
subState
- the initial state for the created account
-
businessAccountId
public UserAccountBuilder businessAccountId(java.lang.String businessAccountId)
Description copied from interface:UserAccountBuilder
The id of the business account that the user account would be linked to (e.g. WhatsApp business number xyz or WeChat official account, etc)- Specified by:
businessAccountId
in interfaceUserAccountBuilder
- Parameters:
businessAccountId
- the id of the business account
-
externalUserId
public UserAccountBuilder externalUserId(java.lang.String externalUserId)
Description copied from interface:UserAccountBuilder
The id of the user within the external system (e.g. the phone number for WhatsApp, the user-id for Facebook account, etc)- Specified by:
externalUserId
in interfaceUserAccountBuilder
- Parameters:
externalUserId
- the id of the external user
-
userAccountDefinitionId
public UserAccountBuilder userAccountDefinitionId(java.lang.String userAccountDefinitionId)
Description copied from interface:UserAccountBuilder
The id of theUserAccountDefinition
that should be used when creating the user account.- Specified by:
userAccountDefinitionId
in interfaceUserAccountBuilder
- Parameters:
userAccountDefinitionId
- the id of the user account definition
-
userAccountDefinitionKey
public UserAccountBuilder userAccountDefinitionKey(java.lang.String userAccountDefinitionKey)
Description copied from interface:UserAccountBuilder
The key of theUserAccountDefinition
that should be used when creating the user account.- Specified by:
userAccountDefinitionKey
in interfaceUserAccountBuilder
- Parameters:
userAccountDefinitionKey
- the key of the user account definition
-
save
public UserAccount save()
Description copied from interface:UserAccountBuilder
Performs the save of the user account- Specified by:
save
in interfaceUserAccountBuilder
- Returns:
- the saved
UserAccount
-
isPropertyModified
public boolean isPropertyModified(java.lang.String property)
-
getUserId
public java.lang.String getUserId()
-
getTenantId
public java.lang.String getTenantId()
-
getName
public java.lang.String getName()
-
getType
public java.lang.String getType()
-
getSubType
public java.lang.String getSubType()
-
getState
public java.lang.String getState()
-
getSubState
public java.lang.String getSubState()
-
getBusinessAccountId
public java.lang.String getBusinessAccountId()
-
getExternalUserId
public java.lang.String getExternalUserId()
-
getUserAccountDefinitionId
public java.lang.String getUserAccountDefinitionId()
-
getUserAccountDefinitionKey
public java.lang.String getUserAccountDefinitionKey()
-
-