org.camunda.bpm.engine.impl.persistence.entity
Class VariableInstanceEntity

java.lang.Object
  extended by org.camunda.bpm.engine.impl.persistence.entity.VariableInstanceEntity
All Implemented Interfaces:
Serializable, CoreVariableInstance, HasRevision, PersistentObject, ValueFields, VariableInstance

public class VariableInstanceEntity
extends Object
implements CoreVariableInstance, VariableInstance, ValueFields, PersistentObject, HasRevision, Serializable

Author:
Tom Baeyens
See Also:
Serialized Form

Field Summary
protected  String activityInstanceId
           
protected  ByteArrayEntity byteArrayValue
           
protected  String byteArrayValueId
           
protected  Object cachedValue
           
protected  String caseExecutionId
           
protected  String caseInstanceId
           
protected  Double doubleValue
           
protected  String errorMessage
           
protected  String executionId
           
protected  String id
           
protected  Long longValue
           
protected  String name
           
protected  String processInstanceId
           
protected  int revision
           
protected  String taskId
           
protected  String textValue
           
protected  String textValue2
           
protected  VariableType type
           
 
Constructor Summary
protected VariableInstanceEntity()
           
 
Method Summary
static VariableInstanceEntity create(String name, VariableType type, Object value)
           
static VariableInstanceEntity createAndInsert(String name, VariableType type, Object value)
           
 void delete()
           
protected  void deleteByteArrayValue()
           
 String getActivityInstanceId()
          Returns the corresponding activity instance id.
 ByteArrayEntity getByteArrayValue()
           
 String getByteArrayValueId()
           
 Object getCachedValue()
           
 String getCaseExecutionId()
          Returns the corresponding case execution id.
 String getCaseInstanceId()
          Returns the corresponding case instance id.
 Double getDoubleValue()
           
 String getErrorMessage()
          If the variable value could not be loaded, this returns the error message.
 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 getProcessInstanceId()
          Returns the corresponding process instance id.
 int getRevision()
           
 int getRevisionNext()
           
 String getTaskId()
          Returns the corresponding task id.
 String getTextValue()
           
 String getTextValue2()
           
 VariableType getType()
           
 String getTypeName()
          Returns the name of the type of this variable instance
 Object getValue()
          Returns the value of this variable instance.
 String getVariableScope()
           
 boolean isAbleToStore(Object value)
           
 void setActivityInstanceId(String acitivtyInstanceId)
           
 void setByteArrayValue(byte[] bytes)
           
 void setByteArrayValueId(String byteArrayValueId)
           
 void setCachedValue(Object cachedValue)
           
 void setCaseExecutionId(String caseExecutionId)
           
 void setCaseInstanceId(String caseInstanceId)
           
 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 setProcessInstanceId(String processInstanceId)
           
 void setRevision(int revision)
           
 void setTaskId(String taskId)
           
 void setTextValue(String textValue)
           
 void setTextValue2(String textValue2)
           
 void setType(VariableType type)
           
 void setValue(Object value)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

id

protected String id

revision

protected int revision

name

protected String name

processInstanceId

protected String processInstanceId

executionId

protected String executionId

taskId

protected String taskId

caseInstanceId

protected String caseInstanceId

caseExecutionId

protected String caseExecutionId

activityInstanceId

protected String activityInstanceId

longValue

protected Long longValue

doubleValue

protected Double doubleValue

textValue

protected String textValue

textValue2

protected String textValue2

byteArrayValue

protected ByteArrayEntity byteArrayValue

byteArrayValueId

protected String byteArrayValueId

cachedValue

protected Object cachedValue

type

protected VariableType type

errorMessage

protected String errorMessage
Constructor Detail

VariableInstanceEntity

protected VariableInstanceEntity()
Method Detail

createAndInsert

public static VariableInstanceEntity createAndInsert(String name,
                                                     VariableType type,
                                                     Object value)

create

public static VariableInstanceEntity create(String name,
                                            VariableType type,
                                            Object value)

setExecution

public void setExecution(ExecutionEntity execution)

delete

public void delete()

getPersistentState

public Object getPersistentState()
Description copied from interface: PersistentObject
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 interface PersistentObject

getRevisionNext

public int getRevisionNext()
Specified by:
getRevisionNext in interface HasRevision

setProcessInstanceId

public void setProcessInstanceId(String processInstanceId)

setExecutionId

public void setExecutionId(String executionId)

setCaseInstanceId

public void setCaseInstanceId(String caseInstanceId)

setCaseExecutionId

public void setCaseExecutionId(String caseExecutionId)

getByteArrayValueId

public String getByteArrayValueId()
Specified by:
getByteArrayValueId in interface ValueFields

setByteArrayValueId

public void setByteArrayValueId(String byteArrayValueId)

getByteArrayValue

public ByteArrayEntity getByteArrayValue()
Specified by:
getByteArrayValue in interface ValueFields

setByteArrayValue

public void setByteArrayValue(byte[] bytes)
Specified by:
setByteArrayValue in interface ValueFields

deleteByteArrayValue

protected void deleteByteArrayValue()

getValue

public Object getValue()
Description copied from interface: VariableInstance
Returns the value of this variable instance.

Specified by:
getValue in interface CoreVariableInstance
Specified by:
getValue in interface VariableInstance

setValue

public void setValue(Object value)

isAbleToStore

public boolean isAbleToStore(Object value)
Specified by:
isAbleToStore in interface CoreVariableInstance

getId

public String getId()
Specified by:
getId in interface PersistentObject
Specified by:
getId in interface VariableInstance
Returns:
the Id of this variable instance

setId

public void setId(String id)
Specified by:
setId in interface PersistentObject

getTextValue

public String getTextValue()
Specified by:
getTextValue in interface ValueFields

getProcessInstanceId

public String getProcessInstanceId()
Description copied from interface: VariableInstance
Returns the corresponding process instance id.

Specified by:
getProcessInstanceId in interface VariableInstance

getExecutionId

public String getExecutionId()
Description copied from interface: VariableInstance
Returns the corresponding execution id.

Specified by:
getExecutionId in interface VariableInstance

getCaseInstanceId

public String getCaseInstanceId()
Description copied from interface: VariableInstance
Returns the corresponding case instance id.

Specified by:
getCaseInstanceId in interface VariableInstance

getCaseExecutionId

public String getCaseExecutionId()
Description copied from interface: VariableInstance
Returns the corresponding case execution id.

Specified by:
getCaseExecutionId in interface VariableInstance

getLongValue

public Long getLongValue()
Specified by:
getLongValue in interface ValueFields

setLongValue

public void setLongValue(Long longValue)
Specified by:
setLongValue in interface ValueFields

getDoubleValue

public Double getDoubleValue()
Specified by:
getDoubleValue in interface ValueFields

setDoubleValue

public void setDoubleValue(Double doubleValue)
Specified by:
setDoubleValue in interface ValueFields

setName

public void setName(String name)

setTextValue

public void setTextValue(String textValue)
Specified by:
setTextValue in interface ValueFields

getName

public String getName()
Description copied from interface: VariableInstance
Returns the name of this variable instance.

Specified by:
getName in interface CoreVariableInstance
Specified by:
getName in interface ValueFields
Specified by:
getName in interface VariableInstance

getRevision

public int getRevision()
Specified by:
getRevision in interface HasRevision

setRevision

public void setRevision(int revision)
Specified by:
setRevision in interface HasRevision

setType

public void setType(VariableType type)

getType

public VariableType getType()

getCachedValue

public Object getCachedValue()
Specified by:
getCachedValue in interface ValueFields

setCachedValue

public void setCachedValue(Object cachedValue)
Specified by:
setCachedValue in interface ValueFields

getTextValue2

public String getTextValue2()
Specified by:
getTextValue2 in interface ValueFields

setTextValue2

public void setTextValue2(String textValue2)
Specified by:
setTextValue2 in interface ValueFields

getTaskId

public String getTaskId()
Description copied from interface: VariableInstance
Returns the corresponding task id.

Specified by:
getTaskId in interface VariableInstance

setTaskId

public void setTaskId(String taskId)

getActivityInstanceId

public String getActivityInstanceId()
Description copied from interface: VariableInstance
Returns the corresponding activity instance id.

Specified by:
getActivityInstanceId in interface VariableInstance

setActivityInstanceId

public void setActivityInstanceId(String acitivtyInstanceId)

getTypeName

public String getTypeName()
Description copied from interface: VariableInstance
Returns the name of the type of this variable instance

Specified by:
getTypeName in interface VariableInstance
Returns:

getErrorMessage

public String getErrorMessage()
Description copied from interface: VariableInstance
If the variable value could not be loaded, this returns the error message.

Specified by:
getErrorMessage in interface VariableInstance
Returns:
an error message indicating why the variable value could not be loaded.

getVariableScope

public String getVariableScope()

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2014 camunda services GmbH. All Rights Reserved.