Move Time to types

Signed-off-by: Katarzyna Treder <katarzyna.treder@h-partners.com>
This commit is contained in:
Katarzyna Treder
2024-12-10 12:19:57 +01:00
parent 622c64c46b
commit 513f006d17
3 changed files with 2 additions and 2 deletions

14
types/time.py Normal file
View File

@@ -0,0 +1,14 @@
#
# Copyright(c) 2019-2021 Intel Corporation
# SPDX-License-Identifier: BSD-3-Clause
#
from attotime import attotimedelta
class Time(attotimedelta):
def total_microseconds(self):
return self.total_nanoseconds() / 1_000
def total_milliseconds(self):
return self.total_nanoseconds() / 1_000_000