(self, other)
| 327 | LALIAS = {k.lower(): v for k, v in ALIAS.items()} |
| 328 | |
| 329 | def __mul__(self, other): |
| 330 | if isinstance(other, self.__class__): |
| 331 | return Area( |
| 332 | default_unit=AREA_PREFIX + self._default_unit, |
| 333 | **{AREA_PREFIX + self.STANDARD_UNIT: (self.standard * other.standard)}, |
| 334 | ) |
| 335 | elif isinstance(other, NUMERIC_TYPES): |
| 336 | return self.__class__( |
| 337 | default_unit=self._default_unit, |
| 338 | **{self.STANDARD_UNIT: (self.standard * other)}, |
| 339 | ) |
| 340 | else: |
| 341 | raise TypeError( |
| 342 | "%(distance)s must be multiplied with number or %(distance)s" |
| 343 | % { |
| 344 | "distance": pretty_name(self.__class__), |
| 345 | } |
| 346 | ) |
| 347 | |
| 348 | |
| 349 | class Area(MeasureBase): |
nothing calls this directly
no test coverage detected