class Rufus::Scheduler::OneTimeJob
def determine_id
def determine_id [ self.class.name.split(':').last.downcase[0..-4], @scheduled_at.to_f, @next_time.to_f, (self.object_id < 0 ? 'm' : '') + self.object_id.to_s ].map(&:to_s).join('_') end
def occurrences(time0, time1)
def occurrences(time0, time1) (time >= time0 && time <= time1) ? [ time ] : [] end
def past?
Used when discard_past? is set to true or :fail at scheduler or job level...
def past? @next_time && @next_time < Time.now - @scheduler.frequency end
def set_next_time(trigger_time, is_post=false, now=nil)
There is no "next time" for one time jobs, hence the false.
def set_next_time(trigger_time, is_post=false, now=nil) @next_time = is_post ? nil : false end