Class: SeeingIsBelieving::EventStream::Handlers::RecordExitEvents
- Inherits:
-
Object
- Object
- SeeingIsBelieving::EventStream::Handlers::RecordExitEvents
- Defined in:
- lib/seeing_is_believing/event_stream/handlers/record_exit_events.rb
Instance Attribute Summary collapse
-
#exitstatus ⇒ Object
readonly
Returns the value of attribute exitstatus.
-
#timeout_seconds ⇒ Object
readonly
Returns the value of attribute timeout_seconds.
Instance Method Summary collapse
- #call(event) ⇒ Object
-
#initialize(next_handler) ⇒ RecordExitEvents
constructor
A new instance of RecordExitEvents.
Constructor Details
#initialize(next_handler) ⇒ RecordExitEvents
Returns a new instance of RecordExitEvents.
10 11 12 |
# File 'lib/seeing_is_believing/event_stream/handlers/record_exit_events.rb', line 10 def initialize(next_handler) @next_handler = next_handler end |
Instance Attribute Details
#exitstatus ⇒ Object (readonly)
Returns the value of attribute exitstatus.
7 8 9 |
# File 'lib/seeing_is_believing/event_stream/handlers/record_exit_events.rb', line 7 def exitstatus @exitstatus end |
#timeout_seconds ⇒ Object (readonly)
Returns the value of attribute timeout_seconds.
8 9 10 |
# File 'lib/seeing_is_believing/event_stream/handlers/record_exit_events.rb', line 8 def timeout_seconds @timeout_seconds end |
Instance Method Details
#call(event) ⇒ Object
14 15 16 17 18 19 20 21 22 |
# File 'lib/seeing_is_believing/event_stream/handlers/record_exit_events.rb', line 14 def call(event) case event when Events::Exitstatus @exitstatus = event.value when Events::Timeout @timeout_seconds = event.seconds end @next_handler.call(event) end |