◆ __init__()
def __init__ |
( |
|
self, |
|
|
|
interval, |
|
|
|
min_interval, |
|
|
|
target, |
|
|
|
name = None |
|
) |
| |
"Run a target function periodically on a background thread.
If the target's return value is false, the executor stops.
:Parameters:
- `interval`: Seconds between calls to `target`.
- `min_interval`: Minimum seconds between calls if `wake` is
called very often.
- `target`: A function.
- `name`: A name to give the underlying thread.
◆ __repr__()
◆ close()
def close |
( |
|
self, |
|
|
|
dummy = None |
|
) |
| |
Stop. To restart, call open().
The dummy parameter allows an executor's close method to be a weakref
callback; see monitor.py.
◆ join()
def join |
( |
|
self, |
|
|
|
timeout = None |
|
) |
| |
◆ open()
Start. Multiple calls have no effect.
Not safe to call from multiple threads at once.
◆ skip_sleep()
◆ update_interval()
def update_interval |
( |
|
self, |
|
|
|
new_interval |
|
) |
| |
◆ wake()
Execute the target function soon.
The documentation for this class was generated from the following file: