class Eventbox::Timer::RepeatedAlarm
Public Class Methods
new(ts, every_seconds, &block)
click to toggle source
@private
Calls superclass method
Eventbox::Timer::Alarm::new
# File lib/eventbox/timer.rb, line 69 def initialize(ts, every_seconds, &block) super(ts, &block) @every_seconds = every_seconds end
Public Instance Methods
fire_then_repeat?(now=Time.now)
click to toggle source
@private
# File lib/eventbox/timer.rb, line 75 def fire_then_repeat?(now=Time.now) @block.call @timestamp = now + @every_seconds true end