utilities.FunctionRepeater
Repeats a function every interval. Ref: https://tinyurl.com/yckgv8m2
Usage
utilities.FunctionRepeater(
interval,
function,
*args,
**kwargs,
)Methods
| Name | Description |
|---|---|
| __init__() | Initialize FunctionRepeater class. |
| start() | Start the function repeater. |
| stop() | Stop the function repeater. |
__init__()
Initialize FunctionRepeater class.
Usage
__init__(interval, function, *args, **kwargs)Parameters
interval: float | int-
Time interval in seconds between function calls.
function: callable-
The function to repeat.
args: tuple = ()-
Positional arguments to pass to the function.
kwargs: dict = {}- Keyword arguments to pass to the function.
start()
Start the function repeater.
Usage
start()stop()
Stop the function repeater.
Usage
stop()