public class VariableInstanceEntity extends Object implements VariableInstance, CoreVariableInstance, ValueFields, DbEntity, DbEntityLifecycleAware, TypedValueUpdateListener, HasDbRevision, HasDbReferences, Serializable
| Modifier and Type | Field and Description |
|---|---|
protected String |
activityInstanceId |
protected String |
batchId |
protected ByteArrayField |
byteArrayField |
protected String |
caseExecutionId |
protected String |
caseInstanceId |
protected String |
configuration |
protected Double |
doubleValue |
protected ExecutionEntity |
execution |
protected String |
executionId |
protected String |
id |
protected boolean |
isConcurrentLocal
Determines whether this variable is supposed to be a local variable
in case of concurrency in its scope.
|
protected boolean |
isTransient
Determines whether this variable is stored in the data base.
|
protected static EnginePersistenceLogger |
LOG |
protected Long |
longValue |
protected String |
name |
protected String |
processDefinitionId |
protected String |
processInstanceId |
protected int |
revision |
protected long |
sequenceCounter |
protected String |
taskId |
protected String |
tenantId |
protected String |
textValue |
protected String |
textValue2 |
protected TypedValueField |
typedValueField |
protected String |
variableScopeId |
| Constructor and Description |
|---|
VariableInstanceEntity() |
VariableInstanceEntity(String name,
TypedValue value,
boolean isTransient) |
| Modifier and Type | Method and Description |
|---|---|
void |
clearValueFields() |
static VariableInstanceEntity |
create(String name,
TypedValue value,
boolean isTransient) |
static VariableInstanceEntity |
createAndInsert(String name,
TypedValue value) |
void |
delete() |
protected void |
deleteByteArrayValue() |
protected void |
ensureExecutionInitialized() |
boolean |
equals(Object obj) |
String |
getActivityInstanceId()
Returns the corresponding activity instance id.
|
String |
getBatchId()
Returns the corresponding batch id.
|
byte[] |
getByteArrayValue() |
String |
getByteArrayValueId() |
CaseExecutionEntity |
getCaseExecution() |
String |
getCaseExecutionId()
Returns the corresponding case execution id.
|
String |
getCaseInstanceId()
Returns the corresponding case instance id.
|
protected ProcessApplicationReference |
getContextProcessApplication() |
Double |
getDoubleValue() |
String |
getErrorMessage()
If the variable value could not be loaded, this returns the error message.
|
ExecutionEntity |
getExecution() |
String |
getExecutionId()
Returns the corresponding execution id.
|
String |
getId() |
Long |
getLongValue() |
String |
getName()
Returns the name of this variable instance.
|
Object |
getPersistentState()
Returns a representation of the object,
as would be stored in the database.
|
String |
getProcessDefinitionId()
Return the corresponding process definition id.
|
String |
getProcessInstanceId()
Returns the corresponding process instance id.
|
Map<String,Class> |
getReferencedEntitiesIdAndClass()
Scope: IN-MEMORY references
|
Set<String> |
getReferencedEntityIds()
Scope: IN-MEMORY references
|
int |
getRevision() |
int |
getRevisionNext() |
long |
getSequenceCounter() |
TypedValueSerializer<?> |
getSerializer() |
String |
getSerializerName() |
protected TaskEntity |
getTask() |
String |
getTaskId()
Returns the corresponding task id.
|
String |
getTenantId()
The id of the tenant this variable belongs to.
|
String |
getTextValue() |
String |
getTextValue2() |
TypedValue |
getTypedValue()
Returns the TypedValue of this variable instance.
|
TypedValue |
getTypedValue(boolean deserializeValue) |
String |
getTypeName()
Returns the name of the type of this variable instance
|
Object |
getValue()
Returns the value of this variable instance.
|
protected VariableScope |
getVariableScope() |
String |
getVariableScopeId() |
int |
hashCode() |
void |
incrementSequenceCounter() |
static void |
insert(VariableInstanceEntity variableInstance) |
boolean |
isConcurrentLocal() |
boolean |
isTransient() |
void |
onImplicitValueUpdate(TypedValue updatedValue)
Called when an implicit update to a typed value is detected
|
void |
postLoad() |
void |
setActivityInstanceId(String activityInstanceId) |
void |
setBatchId(String batchId) |
void |
setByteArrayValue(byte[] bytes) |
void |
setByteArrayValueId(String byteArrayValueId) |
void |
setCaseExecution(CaseExecutionEntity caseExecution) |
void |
setCaseExecutionId(String caseExecutionId) |
void |
setCaseInstanceId(String caseInstanceId) |
void |
setConcurrentLocal(boolean isConcurrentLocal) |
void |
setDoubleValue(Double doubleValue) |
void |
setExecution(ExecutionEntity execution) |
void |
setExecutionId(String executionId) |
void |
setId(String id) |
void |
setLongValue(Long longValue) |
void |
setName(String name) |
void |
setProcessDefinitionId(String processDefinitionId) |
void |
setProcessInstanceId(String processInstanceId) |
void |
setRevision(int revision) |
void |
setSequenceCounter(long sequenceCounter) |
void |
setSerializer(TypedValueSerializer<?> serializer) |
void |
setSerializerName(String type) |
void |
setTask(TaskEntity task) |
void |
setTaskId(String taskId) |
void |
setTenantId(String tenantId) |
void |
setTextValue(String textValue) |
void |
setTextValue2(String textValue2) |
void |
setTransient(boolean isTransient) |
void |
setValue(TypedValue value) |
void |
setVariableScopeId(String variableScopeId) |
String |
toString() |
boolean |
wasCreatedBefore713() |
clone, finalize, getClass, notify, notifyAll, wait, wait, waitgetDependentEntitiesprotected static final EnginePersistenceLogger LOG
protected String id
protected int revision
protected String name
protected String processDefinitionId
protected String processInstanceId
protected String executionId
protected String taskId
protected String batchId
protected String caseInstanceId
protected String caseExecutionId
protected String activityInstanceId
protected String tenantId
protected Long longValue
protected Double doubleValue
protected String textValue
protected String textValue2
protected String variableScopeId
protected ByteArrayField byteArrayField
protected TypedValueField typedValueField
protected String configuration
protected long sequenceCounter
protected boolean isConcurrentLocal
Determines whether this variable is supposed to be a local variable in case of concurrency in its scope. This affects
In the future, this field could be used for restoring the variable distribution when the tree is expanded/compacted multiple times. On expansion, the goal would be to keep concurrentLocal variables always with their concurrent replacing executions while non-concurrentLocal variables stay in the scope execution
protected boolean isTransient
protected ExecutionEntity execution
public VariableInstanceEntity()
public VariableInstanceEntity(String name, TypedValue value, boolean isTransient)
public static VariableInstanceEntity createAndInsert(String name, TypedValue value)
public static void insert(VariableInstanceEntity variableInstance)
public static VariableInstanceEntity create(String name, TypedValue value, boolean isTransient)
public void delete()
public Object getPersistentState()
DbEntitygetPersistentState in interface DbEntitypublic int getRevisionNext()
getRevisionNext in interface HasDbRevisionpublic void setProcessInstanceId(String processInstanceId)
public void setProcessDefinitionId(String processDefinitionId)
public void setExecutionId(String executionId)
public void setCaseInstanceId(String caseInstanceId)
public void setCaseExecutionId(String caseExecutionId)
public void setCaseExecution(CaseExecutionEntity caseExecution)
public String getByteArrayValueId()
public void setByteArrayValueId(String byteArrayValueId)
public byte[] getByteArrayValue()
getByteArrayValue in interface ValueFieldspublic void setByteArrayValue(byte[] bytes)
setByteArrayValue in interface ValueFieldsprotected void deleteByteArrayValue()
public Object getValue()
VariableInstancegetValue in interface VariableInstancepublic TypedValue getTypedValue()
VariableInstancegetTypedValue in interface VariableInstancepublic TypedValue getTypedValue(boolean deserializeValue)
getTypedValue in interface CoreVariableInstancepublic void setValue(TypedValue value)
setValue in interface CoreVariableInstancepublic void clearValueFields()
public String getTypeName()
VariableInstancegetTypeName in interface VariableInstancepublic void postLoad()
postLoad in interface DbEntityLifecycleAwareprotected void ensureExecutionInitialized()
public ExecutionEntity getExecution()
public void setExecution(ExecutionEntity execution)
public CaseExecutionEntity getCaseExecution()
public String getId()
getId in interface DbEntitygetId in interface VariableInstancepublic String getTextValue()
getTextValue in interface ValueFieldspublic String getProcessInstanceId()
VariableInstancegetProcessInstanceId in interface VariableInstancepublic String getProcessDefinitionId()
VariableInstancegetProcessDefinitionId in interface VariableInstancepublic String getExecutionId()
VariableInstancegetExecutionId in interface VariableInstancepublic String getCaseInstanceId()
VariableInstancegetCaseInstanceId in interface VariableInstancepublic String getCaseExecutionId()
VariableInstancegetCaseExecutionId in interface VariableInstancepublic Long getLongValue()
getLongValue in interface ValueFieldspublic void setLongValue(Long longValue)
setLongValue in interface ValueFieldspublic Double getDoubleValue()
getDoubleValue in interface ValueFieldspublic void setDoubleValue(Double doubleValue)
setDoubleValue in interface ValueFieldspublic void setName(String name)
public void setTextValue(String textValue)
setTextValue in interface ValueFieldspublic String getName()
VariableInstancegetName in interface CoreVariableInstancegetName in interface NameablegetName in interface VariableInstancepublic int getRevision()
getRevision in interface HasDbRevisionpublic void setRevision(int revision)
setRevision in interface HasDbRevisionpublic void setSerializer(TypedValueSerializer<?> serializer)
public void setSerializerName(String type)
public TypedValueSerializer<?> getSerializer()
public String getTextValue2()
getTextValue2 in interface ValueFieldspublic void setTextValue2(String textValue2)
setTextValue2 in interface ValueFieldspublic String getTaskId()
VariableInstancegetTaskId in interface VariableInstancepublic void setTaskId(String taskId)
public String getBatchId()
VariableInstancegetBatchId in interface VariableInstancepublic void setBatchId(String batchId)
public void setTask(TaskEntity task)
public String getActivityInstanceId()
VariableInstancegetActivityInstanceId in interface VariableInstancepublic void setActivityInstanceId(String activityInstanceId)
public String getSerializerName()
public String getErrorMessage()
VariableInstancegetErrorMessage in interface VariableInstancepublic String getVariableScopeId()
public void setVariableScopeId(String variableScopeId)
protected VariableScope getVariableScope()
protected TaskEntity getTask()
public long getSequenceCounter()
public void setSequenceCounter(long sequenceCounter)
public void incrementSequenceCounter()
public boolean isConcurrentLocal()
public void setConcurrentLocal(boolean isConcurrentLocal)
public void onImplicitValueUpdate(TypedValue updatedValue)
TypedValueUpdateListeneronImplicitValueUpdate in interface TypedValueUpdateListenerprotected ProcessApplicationReference getContextProcessApplication()
public void setTransient(boolean isTransient)
isTransient - true, if the variable is not stored in the data base.
Default is false.public boolean isTransient()
true, if the variable is transient. A transient
variable is not stored in the data base.public String getTenantId()
VariableInstancenull
if the variable belongs to no single tenant.getTenantId in interface VariableInstancepublic void setTenantId(String tenantId)
public Set<String> getReferencedEntityIds()
HasDbReferencesScope: IN-MEMORY references
getReferencedEntityIds in interface HasDbReferencespublic Map<String,Class> getReferencedEntitiesIdAndClass()
HasDbReferencesScope: IN-MEMORY references
getReferencedEntitiesIdAndClass in interface HasDbReferencespublic boolean wasCreatedBefore713()
true processDefinitionId is introduced in 7.13,
the check is used to created missing history at LegacyBehavior#createMissingHistoricVariablesCopyright © 2022. All rights reserved.