Module: Temporal::Concerns::Payloads
- Included in:
- Activity::TaskProcessor, Temporal::Client::GRPCClient, Temporal::Client::Serializer::CompleteWorkflow, Temporal::Client::Serializer::ContinueAsNew, Temporal::Client::Serializer::Failure, Temporal::Client::Serializer::RecordMarker, Temporal::Client::Serializer::ScheduleActivity, Temporal::Client::Serializer::StartChildWorkflow, Metadata, Workflow::Errors, Workflow::StateManager
- Defined in:
- lib/temporal/concerns/payloads.rb
Instance Method Summary collapse
- #from_details_payloads(payloads) ⇒ Object
- #from_payload(payload) ⇒ Object
- #from_payloads(payloads) ⇒ Object
- #from_result_payloads(payloads) ⇒ Object
- #from_signal_payloads(payloads) ⇒ Object
- #to_details_payloads(data) ⇒ Object
- #to_payload(data) ⇒ Object
- #to_payloads(data) ⇒ Object
- #to_result_payloads(data) ⇒ Object
- #to_signal_payloads(data) ⇒ Object
Instance Method Details
#from_details_payloads(payloads) ⇒ Object
16 17 18 |
# File 'lib/temporal/concerns/payloads.rb', line 16 def from_details_payloads(payloads) from_payloads(payloads)&.first end |
#from_payload(payload) ⇒ Object
8 9 10 |
# File 'lib/temporal/concerns/payloads.rb', line 8 def from_payload(payload) payload_converter.from_payload(payload) end |
#from_payloads(payloads) ⇒ Object
4 5 6 |
# File 'lib/temporal/concerns/payloads.rb', line 4 def from_payloads(payloads) payload_converter.from_payloads(payloads) end |
#from_result_payloads(payloads) ⇒ Object
12 13 14 |
# File 'lib/temporal/concerns/payloads.rb', line 12 def from_result_payloads(payloads) from_payloads(payloads)&.first end |
#from_signal_payloads(payloads) ⇒ Object
20 21 22 |
# File 'lib/temporal/concerns/payloads.rb', line 20 def from_signal_payloads(payloads) from_payloads(payloads)&.first end |
#to_details_payloads(data) ⇒ Object
36 37 38 |
# File 'lib/temporal/concerns/payloads.rb', line 36 def to_details_payloads(data) to_payloads([data]) end |
#to_payload(data) ⇒ Object
28 29 30 |
# File 'lib/temporal/concerns/payloads.rb', line 28 def to_payload(data) payload_converter.to_payload(data) end |
#to_payloads(data) ⇒ Object
24 25 26 |
# File 'lib/temporal/concerns/payloads.rb', line 24 def to_payloads(data) payload_converter.to_payloads(data) end |
#to_result_payloads(data) ⇒ Object
32 33 34 |
# File 'lib/temporal/concerns/payloads.rb', line 32 def to_result_payloads(data) to_payloads([data]) end |
#to_signal_payloads(data) ⇒ Object
40 41 42 |
# File 'lib/temporal/concerns/payloads.rb', line 40 def to_signal_payloads(data) to_payloads([data]) end |