Public Member Functions | |
def | __enter__ (self) |
def | __exit__ (self, tpe, value, tb) |
def | __init__ (self) |
def | __str__ (self) |
def | lap (self) |
def | start (self) |
def | stop (self) |
Public Attributes | |
time | |
timestamp | |
Simple time measuring class.
Definition at line 64 of file scripts/mycroft/metrics/__init__.py.
def mycroft.metrics.Stopwatch.__init__ | ( | self | ) |
Definition at line 68 of file scripts/mycroft/metrics/__init__.py.
def mycroft.metrics.Stopwatch.__enter__ | ( | self | ) |
Start stopwatch when entering with-block.
Definition at line 93 of file scripts/mycroft/metrics/__init__.py.
def mycroft.metrics.Stopwatch.__exit__ | ( | self, | |
tpe, | |||
value, | |||
tb | |||
) |
Stop stopwatch when exiting with-block.
Definition at line 99 of file scripts/mycroft/metrics/__init__.py.
def mycroft.metrics.Stopwatch.__str__ | ( | self | ) |
Definition at line 105 of file scripts/mycroft/metrics/__init__.py.
def mycroft.metrics.Stopwatch.lap | ( | self | ) |
Definition at line 78 of file scripts/mycroft/metrics/__init__.py.
def mycroft.metrics.Stopwatch.start | ( | self | ) |
Start a time measurement
Definition at line 72 of file scripts/mycroft/metrics/__init__.py.
def mycroft.metrics.Stopwatch.stop | ( | self | ) |
Stop a running time measurement. returns the measured time
Definition at line 84 of file scripts/mycroft/metrics/__init__.py.
mycroft.metrics.Stopwatch.time |
Definition at line 70 of file scripts/mycroft/metrics/__init__.py.
mycroft.metrics.Stopwatch.timestamp |
Definition at line 69 of file scripts/mycroft/metrics/__init__.py.