Move temperature conversions to entity base class (7/8) (#54482)

This commit is contained in:
Erik Montnemery 2021-08-11 18:57:50 +02:00 committed by GitHub
parent 41f3c2766c
commit 94a264afaf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
54 changed files with 153 additions and 153 deletions

View file

@ -82,12 +82,12 @@ class VL53L1XSensor(SensorEntity):
return self._name
@property
def state(self) -> int:
def native_value(self) -> int:
"""Return the state of the sensor."""
return self._state
@property
def unit_of_measurement(self) -> str:
def native_unit_of_measurement(self) -> str:
"""Return the unit of measurement."""
return self._unit_of_measurement