class RFlow::Message::ProcessingEvent
One processing event in the message's provenance.
Attributes
completed_at[RW]
The time processing ended, in XML schema format. @return [String]
component_instance_uuid[R]
The UUID of the component doing the processing. @return [String]
context[RW]
Arbitrary context bytes. @return [String]
started_at[R]
The time processing started, in XML schema format. @return [String]
Public Class Methods
new(component_instance_uuid, started_at = nil, completed_at = nil, context = nil)
click to toggle source
# File lib/rflow/message.rb, line 150 def initialize(component_instance_uuid, started_at = nil, completed_at = nil, context = nil) @component_instance_uuid = component_instance_uuid @started_at = case started_at when String; Time.xmlschema(started_at) when Time; started_at else nil; end @completed_at = case completed_at when String; Time.xmlschema(completed_at) when Time; completed_at else nil; end @context = context end
Public Instance Methods
to_hash()
click to toggle source
Represent the processing event as a hash. @return [Hash]
# File lib/rflow/message.rb, line 165 def to_hash { 'component_instance_uuid' => component_instance_uuid.to_s, 'started_at' => started_at ? started_at.xmlschema(6) : nil, 'completed_at' => completed_at ? completed_at.xmlschema(6) : nil, 'context' => context ? context.to_s : nil, } end