class documentation

class botService(service.MultiService): (source)

View In Hierarchy

Wrapper class for the scheduling functions of twisted.internet.reactor.ReactorTime

Method __init__ Undocumented
Method callAtDatetime executes function at datetime dt with arguments *args and keyword arguments **kwargs
Method callLater executes function after time seconds with arguments *args and keyword arguments **kwargs
Method callPeriodic executes function every delay seconds with keyword arguments **kwargs
Method cancelCallLater cancel a delayed call
Class Variable name Undocumented
Instance Variable logger Undocumented
Instance Variable parent Undocumented
Instance Variable root Undocumented
def __init__(self, root, parent): (source)

Undocumented

def callAtDatetime(self, dt, function, *args, **kwargs): (source)

executes function at datetime dt with arguments *args and keyword arguments **kwargs

Parameters
dt:datetimedatetime object with the time when to execute function
function:callablethe function to call
*args:tuplearguments for the function
**kwargs:dictkeyworded arguments for the function
def callLater(self, time, function, *args, **kwargs): (source)

executes function after time seconds with arguments *args and keyword arguments **kwargs

Parameters
time:intseconds to wait before executing function
function:callablethe function to call
*args:tuplearguments for the function
**kwargs:dictkeyworded arguments for the function
def callPeriodic(self, delay, function, kwargs={}): (source)

executes function every delay seconds with keyword arguments **kwargs

Parameters
delay:intthe delay between two runs of the function
function:callablethe function to be called
kwargs:dictthe keyworded arguments for the function
Note

add the possibility to give a *args-tuple (need to know how to merge two tuples)

if the function returns a value which evaluates to False, the periodic call will be canceled

def cancelCallLater(self, callID): (source)

cancel a delayed call

Parameters
callIDthe call to cancel (id returned in callLater)
name: str = (source)

Undocumented

Undocumented

Undocumented

Undocumented