Class IdentityLinkEntity
- java.lang.Object
-
- org.camunda.bpm.engine.impl.persistence.entity.IdentityLinkEntity
-
- All Implemented Interfaces:
Serializable
,DbEntity
,HasDbReferences
,IdentityLink
public class IdentityLinkEntity extends Object implements Serializable, IdentityLink, DbEntity, HasDbReferences
- Author:
- Joram Barrez, Deivarayan Azhagappan
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected String
groupId
protected String
id
protected static EnginePersistenceLogger
LOG
protected ProcessDefinitionEntity
processDef
protected String
processDefId
protected TaskEntity
task
protected String
taskId
protected String
tenantId
protected String
type
protected String
userId
-
Constructor Summary
Constructors Constructor Description IdentityLinkEntity()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static IdentityLinkEntity
createAndInsert()
void
delete()
void
delete(boolean withHistory)
void
fireHistoricIdentityLinkEvent(HistoryEventType eventType)
String
getGroupId()
If the identity link involves a group, then this will be a non-null id of a group.String
getId()
Get the Id of identityLinkObject
getPersistentState()
Returns a representation of the object, as would be stored in the database.ProcessDefinitionEntity
getProcessDef()
String
getProcessDefId()
Get the process definition idMap<String,Class>
getReferencedEntitiesIdAndClass()
Scope: IN-MEMORY referencesSet<String>
getReferencedEntityIds()
Scope: IN-MEMORY referencesTaskEntity
getTask()
String
getTaskId()
The id of the task associated with this identity link.String
getTenantId()
The id of the tenant associated with this identity link.String
getType()
Returns the type of link.String
getUserId()
If the identity link involves a user, then this will be a non-null id of a user.void
insert()
boolean
isGroup()
boolean
isUser()
static IdentityLinkEntity
newIdentityLink()
void
setGroupId(String groupId)
void
setId(String id)
void
setProcessDef(ProcessDefinitionEntity processDef)
void
setProcessDefId(String processDefId)
void
setTask(TaskEntity task)
void
setTenantId(String tenantId)
void
setType(String type)
void
setUserId(String userId)
String
toString()
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.camunda.bpm.engine.impl.db.HasDbReferences
getDependentEntities
-
-
-
-
Field Detail
-
LOG
protected static final EnginePersistenceLogger LOG
-
id
protected String id
-
type
protected String type
-
userId
protected String userId
-
groupId
protected String groupId
-
taskId
protected String taskId
-
processDefId
protected String processDefId
-
tenantId
protected String tenantId
-
task
protected TaskEntity task
-
processDef
protected ProcessDefinitionEntity processDef
-
-
Method Detail
-
getPersistentState
public Object getPersistentState()
Description copied from interface:DbEntity
Returns a representation of the object, as would be stored in the database. Used when deciding if updates have occurred to the object or not since it was last loaded.- Specified by:
getPersistentState
in interfaceDbEntity
-
createAndInsert
public static IdentityLinkEntity createAndInsert()
-
newIdentityLink
public static IdentityLinkEntity newIdentityLink()
-
insert
public void insert()
-
delete
public void delete()
-
delete
public void delete(boolean withHistory)
-
isUser
public boolean isUser()
-
isGroup
public boolean isGroup()
-
getId
public String getId()
Description copied from interface:IdentityLink
Get the Id of identityLink- Specified by:
getId
in interfaceDbEntity
- Specified by:
getId
in interfaceIdentityLink
-
getType
public String getType()
Description copied from interface:IdentityLink
Returns the type of link. SeeIdentityLinkType
for the native supported types by the process engine.- Specified by:
getType
in interfaceIdentityLink
-
setType
public void setType(String type)
-
getUserId
public String getUserId()
Description copied from interface:IdentityLink
If the identity link involves a user, then this will be a non-null id of a user. That userId can be used to query for user information through theUserQuery
API.- Specified by:
getUserId
in interfaceIdentityLink
-
setUserId
public void setUserId(String userId)
-
getGroupId
public String getGroupId()
Description copied from interface:IdentityLink
If the identity link involves a group, then this will be a non-null id of a group. That groupId can be used to query for user information through theGroupQuery
API.- Specified by:
getGroupId
in interfaceIdentityLink
-
setGroupId
public void setGroupId(String groupId)
-
getTaskId
public String getTaskId()
Description copied from interface:IdentityLink
The id of the task associated with this identity link.- Specified by:
getTaskId
in interfaceIdentityLink
-
getProcessDefId
public String getProcessDefId()
Description copied from interface:IdentityLink
Get the process definition id- Specified by:
getProcessDefId
in interfaceIdentityLink
-
setProcessDefId
public void setProcessDefId(String processDefId)
-
getTenantId
public String getTenantId()
Description copied from interface:IdentityLink
The id of the tenant associated with this identity link.- Specified by:
getTenantId
in interfaceIdentityLink
-
setTenantId
public void setTenantId(String tenantId)
-
getTask
public TaskEntity getTask()
-
setTask
public void setTask(TaskEntity task)
-
getProcessDef
public ProcessDefinitionEntity getProcessDef()
-
setProcessDef
public void setProcessDef(ProcessDefinitionEntity processDef)
-
fireHistoricIdentityLinkEvent
public void fireHistoricIdentityLinkEvent(HistoryEventType eventType)
-
getReferencedEntityIds
public Set<String> getReferencedEntityIds()
Description copied from interface:HasDbReferences
Scope: IN-MEMORY references
- Specified by:
getReferencedEntityIds
in interfaceHasDbReferences
- Returns:
- the ids of the entities that this entity references. Should only return ids for entities of the same type
-
getReferencedEntitiesIdAndClass
public Map<String,Class> getReferencedEntitiesIdAndClass()
Description copied from interface:HasDbReferences
Scope: IN-MEMORY references
- Specified by:
getReferencedEntitiesIdAndClass
in interfaceHasDbReferences
- Returns:
- a map of the ids and the entities' classes that this entity references. It's used when trying to determine if there was an Optimistic Locking occurrence on an INSERT or UPDATE of an object of this type.
-
-