Package turbogears :: Module scheduler :: Class Scheduler

Class Scheduler

source code

object --+
         |
        Scheduler
Known Subclasses:

The Scheduler itself.

Instance Methods
 
__init__(self)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code
 
add_interval_task(self, action, taskname, initialdelay, interval, processmethod, args, kw)
Add a new Interval Task to the schedule.
source code
 
add_single_task(self, action, taskname, initialdelay, processmethod, args, kw)
Add a new task to the scheduler that will only be executed once.
source code
 
add_daytime_task(self, action, taskname, weekdays, monthdays, timeonday, processmethod, args, kw)
Add a new Day Task (Weekday or Monthday) to the schedule.
source code
 
add_cron_like_task(self, action, taskname, cron_str, processmethod, args, kw)
Add a new Cron-like Task to the schedule.
source code
 
schedule_task(self, task, delay)
Add a new task to the scheduler with the given delay (seconds).
source code
 
schedule_task_abs(self, task, abstime)
Add a new task to the scheduler for the given absolute time value.
source code
 
start(self)
Start the scheduler.
source code
 
stop(self)
Remove all pending tasks and stop the scheduler.
source code
 
cancel(self, task)
Cancel given scheduled task.
source code
 
rename(self, taskname, newname)
Rename a scheduled task.
source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties

Inherited from object: __class__

Method Details

__init__(self)
(Constructor)

source code 

x.__init__(...) initializes x; see x.__class__.__doc__ for signature

Overrides: object.__init__
(inherited documentation)

add_interval_task(self, action, taskname, initialdelay, interval, processmethod, args, kw)

source code 

Add a new Interval Task to the schedule.

A very short initialdelay or one of zero cannot be honored, you will see a slight delay before the task is first executed. This is because the scheduler needs to pick it up in its loop.

schedule_task(self, task, delay)

source code 

Add a new task to the scheduler with the given delay (seconds).

Low-level method for internal use.

schedule_task_abs(self, task, abstime)

source code 

Add a new task to the scheduler for the given absolute time value.

Low-level method for internal use.