Class: YPetri::Simulation::Timeless::Recorder
- Defined in:
- lib/y_petri/simulation/timeless/recorder.rb
Overview
A timeless recorder.
Constant Summary
Constants inherited from Recorder
Recorder::SAMPLING_DECIMAL_PLACES
Instance Attribute Summary collapse
-
#next_event ⇒ Object
readonly
Returns the value of attribute next_event.
Attributes inherited from Recorder
Instance Method Summary collapse
-
#reset!(**nn) ⇒ Object
Like YPetri::Simulation::Recording#reset, but allowing for additional named argument
:next_sample
that sets the event (label, hash key) of the next sample.
Methods inherited from Recorder
#alert, #initialize, #new_recording, #recording
Constructor Details
This class inherits a constructor from YPetri::Simulation::Recorder
Instance Attribute Details
#next_event ⇒ Object (readonly)
Returns the value of attribute next_event.
5 6 7 |
# File 'lib/y_petri/simulation/timeless/recorder.rb', line 5 def next_event @next_event end |
Instance Method Details
#reset!(**nn) ⇒ Object
Like YPetri::Simulation::Recording#reset, but allowing for additional named argument :next_sample
that sets the event (label, hash key) of the next sample.
11 12 13 14 |
# File 'lib/y_petri/simulation/timeless/recorder.rb', line 11 def reset! **nn super @next_event = nn[:next_event] || 0 end |