Class: Workers::PeriodicTimer

Inherits:
Timer
  • Object
show all
Defined in:
lib/workers/periodic_timer.rb

Instance Attribute Summary

Attributes inherited from Timer

#delay, #repeat

Instance Method Summary collapse

Methods inherited from Timer

#<=>, #cancel, #fire, #overdue?, #reset, #sec_remaining

Constructor Details

#initialize(delay, options = {}, &block) ⇒ PeriodicTimer

Returns a new instance of PeriodicTimer.



3
4
5
6
7
# File 'lib/workers/periodic_timer.rb', line 3

def initialize(delay, options = {}, &block)
  options[:repeat] = true

  super(delay, options, &block)
end