Class: Temporalio::WorkflowHistory
- Inherits:
-
Object
- Object
- Temporalio::WorkflowHistory
- Defined in:
- lib/temporalio/workflow_history.rb
Overview
Representation of a workflow’s history.
Instance Attribute Summary collapse
-
#events ⇒ Object
readonly
History events for the workflow.
Instance Method Summary collapse
-
#workflow_id ⇒ String
ID of the workflow, extracted from the first event.
Instance Attribute Details
#events ⇒ Object (readonly)
History events for the workflow.
7 8 9 |
# File 'lib/temporalio/workflow_history.rb', line 7 def events @events end |
Instance Method Details
#workflow_id ⇒ String
Returns ID of the workflow, extracted from the first event.
15 16 17 18 19 20 |
# File 'lib/temporalio/workflow_history.rb', line 15 def workflow_id start = events.first&.workflow_execution_started_event_attributes raise 'First event not a start event' if start.nil? start.workflow_id end |