Class: Bonito::SerialScheduler
- Defined in:
- lib/bonito/serial_timeline.rb
Overview
:nodoc:
Instance Method Summary collapse
-
#each ⇒ Object
:reek:NestedIterators: Not sure how this can be avoided nicely at the moment.
-
#initialize(serial, starting_offset, parent_scope, opts = {}) ⇒ SerialScheduler
constructor
A new instance of SerialScheduler.
Constructor Details
#initialize(serial, starting_offset, parent_scope, opts = {}) ⇒ SerialScheduler
Returns a new instance of SerialScheduler.
10 11 12 13 |
# File 'lib/bonito/serial_timeline.rb', line 10 def initialize(serial, starting_offset, parent_scope, opts = {}) super serial, starting_offset, parent_scope.push, opts @distribution = Distribution.new starting_offset, serial, opts end |
Instance Method Details
#each ⇒ Object
:reek:NestedIterators: Not sure how this can be avoided nicely at the moment
17 18 19 20 21 22 23 |
# File 'lib/bonito/serial_timeline.rb', line 17 def each @distribution.each do |timeline, offset| timeline.scheduler(offset, scope, opts).each do |moment| yield moment end end end |