Add NORMALISED_UNIT to UnitConverter (#78920)

* Add NORMALISED_UNIT to UnitConverter

* Adjust statistics

* Rename
This commit is contained in:
epenet
2022-09-22 08:50:08 +02:00
committed by GitHub
parent f5120872aa
commit 713fb874a8
8 changed files with 49 additions and 43 deletions

View File

@ -31,6 +31,7 @@ class UnitConverter(Protocol):
"""Define the format of a conversion utility."""
VALID_UNITS: tuple[str, ...]
NORMALIZED_UNIT: str
def convert(self, value: float, from_unit: str, to_unit: str) -> float:
"""Convert one unit of measurement to another."""