netsvc: API doc title and docstring fixes
bzr revid: xrg@linux.gr-20110623090357-vcr58sj3sbgd1r2i
This commit is contained in:
parent
cf6e623f7d
commit
18c480d1cb
|
@ -63,6 +63,9 @@ def close_socket(sock):
|
||||||
sock.close()
|
sock.close()
|
||||||
|
|
||||||
|
|
||||||
|
#.apidoc title: Common Services: netsvc
|
||||||
|
#.apidoc module-mods: member-order: bysource
|
||||||
|
|
||||||
class Service(object):
|
class Service(object):
|
||||||
""" Base class for *Local* services
|
""" Base class for *Local* services
|
||||||
|
|
||||||
|
@ -251,16 +254,19 @@ def init_alternative_logger():
|
||||||
class Agent(object):
|
class Agent(object):
|
||||||
""" Singleton that keeps track of cancellable tasks to run at a given
|
""" Singleton that keeps track of cancellable tasks to run at a given
|
||||||
timestamp.
|
timestamp.
|
||||||
The tasks are caracterised by:
|
|
||||||
|
The tasks are characterised by:
|
||||||
|
|
||||||
* a timestamp
|
* a timestamp
|
||||||
* the database on which the task run
|
* the database on which the task run
|
||||||
* the function to call
|
* the function to call
|
||||||
* the arguments and keyword arguments to pass to the function
|
* the arguments and keyword arguments to pass to the function
|
||||||
|
|
||||||
Implementation details:
|
Implementation details:
|
||||||
Tasks are stored as list, allowing the cancellation by setting
|
|
||||||
|
- Tasks are stored as list, allowing the cancellation by setting
|
||||||
the timestamp to 0.
|
the timestamp to 0.
|
||||||
A heapq is used to store tasks, so we don't need to sort
|
- A heapq is used to store tasks, so we don't need to sort
|
||||||
tasks ourself.
|
tasks ourself.
|
||||||
"""
|
"""
|
||||||
__tasks = []
|
__tasks = []
|
||||||
|
|
Loading…
Reference in New Issue