This module provides some utilities used by other modules.
Decorator usefull to access to a function with a lock named lock
Parameters: | lock (threading.Lock or threading.Condition) – the name of the lock to use |
---|---|
Returns: | the decorated function |
Exception that occurs when no checkpoint is set and it is needed
Parameters: | msg (string) – the message |
---|
This class provides an utility to calculates elapsed time since a start/check point
Parameters: |
|
---|
Create the timer with the given starting time and an eventual checkpoint
Parameters: |
|
---|
The last checkpoint
Getter: | Returns checkpoint |
---|---|
Setter: | Sets the checkpoint |
Type: | float |
Return the elapsed time since the timer starting time
Returns: | the total elapsed time since the starting time of the timer |
---|---|
Return type: | float |
Return the elapsed time since the last checkpoint
Returns: | the elapsed time since the last checkpoint |
||||
---|---|---|---|---|---|
Return type: | float |
||||
Raises: |
|
Return the elapsed time since the last checkpoint and change the checkpoint
The checkpoint is changed with new_checkpoint if change is True. If new_checkpoint is None, then to checkpoint is assigned the current time.
Parameters: |
|
||||
---|---|---|---|---|---|
Returns: | the elapsed time since the last checkpoint |
||||
Return type: | float |
||||
Raise: |
|