Module: Cadence::Workflow::Serializer
- Defined in:
- lib/cadence/workflow/serializer.rb,
lib/cadence/workflow/serializer/base.rb,
lib/cadence/workflow/serializer/start_timer.rb,
lib/cadence/workflow/serializer/cancel_timer.rb,
lib/cadence/workflow/serializer/fail_workflow.rb,
lib/cadence/workflow/serializer/record_marker.rb,
lib/cadence/workflow/serializer/complete_workflow.rb,
lib/cadence/workflow/serializer/schedule_activity.rb,
lib/cadence/workflow/serializer/start_child_workflow.rb,
lib/cadence/workflow/serializer/request_activity_cancellation.rb
Defined Under Namespace
Classes: Base, CancelTimer, CompleteWorkflow, FailWorkflow, RecordMarker, RequestActivityCancellation, ScheduleActivity, StartChildWorkflow, StartTimer
Constant Summary collapse
- SERIALIZERS_MAP =
{ Workflow::Decision::ScheduleActivity => Serializer::ScheduleActivity, Workflow::Decision::StartChildWorkflow => Serializer::StartChildWorkflow, Workflow::Decision::RequestActivityCancellation => Serializer::RequestActivityCancellation, Workflow::Decision::RecordMarker => Serializer::RecordMarker, Workflow::Decision::StartTimer => Serializer::StartTimer, Workflow::Decision::CancelTimer => Serializer::CancelTimer, Workflow::Decision::CompleteWorkflow => Serializer::CompleteWorkflow, Workflow::Decision::FailWorkflow => Serializer::FailWorkflow }.freeze
Class Method Summary collapse
Class Method Details
.serialize(object) ⇒ Object
25 26 27 28 |
# File 'lib/cadence/workflow/serializer.rb', line 25 def self.serialize(object) serializer = SERIALIZERS_MAP[object.class] serializer.new(object).to_thrift end |