Module: Sidetiq::Schedulable::ClassMethods
- Includes:
- Sidetiq::SubclassTracking
- Defined in:
- lib/sidetiq/schedulable.rb
Instance Attribute Summary collapse
-
#schedule ⇒ Object
Public: Returns the Sidetiq::Schedule for this worker.
Instance Method Summary collapse
-
#last_scheduled_occurrence ⇒ Object
Public: Returns a Float timestamp of the last scheduled run.
-
#next_scheduled_occurrence ⇒ Object
Public: Returns a Float timestamp of the next scheduled run.
-
#recurrence(options = {}, &block) ⇒ Object
:nodoc:.
Methods included from Sidetiq::SubclassTracking
Instance Attribute Details
Instance Method Details
#last_scheduled_occurrence ⇒ Object
Public: Returns a Float timestamp of the last scheduled run.
22 23 24 |
# File 'lib/sidetiq/schedulable.rb', line 22 def last_scheduled_occurrence "last" end |
#next_scheduled_occurrence ⇒ Object
Public: Returns a Float timestamp of the next scheduled run.
32 33 34 |
# File 'lib/sidetiq/schedulable.rb', line 32 def next_scheduled_occurrence "next" end |
#recurrence(options = {}, &block) ⇒ Object
:nodoc:
36 37 38 39 |
# File 'lib/sidetiq/schedulable.rb', line 36 def recurrence( = {}, &block) # :nodoc: schedule.instance_eval(&block) schedule.() end |