Record Class WorkflowInstanceEntity
java.lang.Object
java.lang.Record
com.yworkflow.instance.repository.WorkflowInstanceEntity
- Record Components:
workflowInstanceId- the unique identifier for this workflow instancestatus- the current status of the workflow instanceworkflowDefinitionId- the ID of the workflow definition this instance belongs tostates- the list of current state instanceshistoryStates- the list of historical state instancesattributes- the list of attributes associated with this workflow instance
public record WorkflowInstanceEntity(String workflowInstanceId, String status, String workflowDefinitionId, List<StateInstanceEntity> states, List<StateInstanceEntity> historyStates, List<AttributeEntity> attributes)
extends Record
Represents a workflow instance entity in the repository layer. WorkflowInstanceEntity
encapsulates all the data needed to persist and retrieve a workflow instance, including its
current state, history, and attributes.
- Since:
- 1.0
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionWorkflowInstanceEntity(String workflowInstanceId, String status, String workflowDefinitionId, List<StateInstanceEntity> states, List<StateInstanceEntity> historyStates, List<AttributeEntity> attributes) Creates an instance of aWorkflowInstanceEntityrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theattributesrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of thehistoryStatesrecord component.states()Returns the value of thestatesrecord component.status()Returns the value of thestatusrecord component.final StringtoString()Returns a string representation of this record class.Returns the value of theworkflowDefinitionIdrecord component.Returns the value of theworkflowInstanceIdrecord component.
-
Constructor Details
-
WorkflowInstanceEntity
public WorkflowInstanceEntity(String workflowInstanceId, String status, String workflowDefinitionId, List<StateInstanceEntity> states, List<StateInstanceEntity> historyStates, List<AttributeEntity> attributes) Creates an instance of aWorkflowInstanceEntityrecord class.- Parameters:
workflowInstanceId- the value for theworkflowInstanceIdrecord componentstatus- the value for thestatusrecord componentworkflowDefinitionId- the value for theworkflowDefinitionIdrecord componentstates- the value for thestatesrecord componenthistoryStates- the value for thehistoryStatesrecord componentattributes- the value for theattributesrecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
workflowInstanceId
Returns the value of theworkflowInstanceIdrecord component.- Returns:
- the value of the
workflowInstanceIdrecord component
-
status
Returns the value of thestatusrecord component.- Returns:
- the value of the
statusrecord component
-
workflowDefinitionId
Returns the value of theworkflowDefinitionIdrecord component.- Returns:
- the value of the
workflowDefinitionIdrecord component
-
states
Returns the value of thestatesrecord component.- Returns:
- the value of the
statesrecord component
-
historyStates
Returns the value of thehistoryStatesrecord component.- Returns:
- the value of the
historyStatesrecord component
-
attributes
Returns the value of theattributesrecord component.- Returns:
- the value of the
attributesrecord component
-