Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.unifiprotect.sensor.ProtectSensorEntityDescription Class Reference
Inheritance diagram for homeassistant.components.unifiprotect.sensor.ProtectSensorEntityDescription:
[legend]
Collaboration diagram for homeassistant.components.unifiprotect.sensor.ProtectSensorEntityDescription:
[legend]

Public Member Functions

None __post_init__ (self)
 
- Public Member Functions inherited from homeassistant.components.unifiprotect.entity.ProtectEntityDescription
Any get_ufp_value (self, T obj)
 
- Public Member Functions inherited from homeassistant.util.frozen_dataclass_compat.FrozenOrThawed
None __init__ (cls, str name, tuple[type,...] bases, dict[Any, Any] namespace, **Any kwargs)
 
Any __new__ (mcs, str name, tuple[type,...] bases, dict[Any, Any] namespace, bool frozen_or_thawed=False, **Any kwargs)
 

Static Public Attributes

 None
 
- Static Public Attributes inherited from homeassistant.components.unifiprotect.entity.ProtectEntityDescription
 None
 
- Static Public Attributes inherited from homeassistant.helpers.entity.EntityDescription
 bool
 
 None
 
- Static Public Attributes inherited from homeassistant.components.sensor.SensorEntityDescription
 None
 

Private Member Functions

Any _rounded_value (self, int precision, Callable[[T], Any] getter, T obj)
 

Detailed Description

Describes UniFi Protect Sensor entity.

Definition at line 62 of file sensor.py.

Member Function Documentation

◆ __post_init__()

None homeassistant.components.unifiprotect.sensor.ProtectSensorEntityDescription.__post_init__ (   self)
Ensure values are rounded if precision is set.

Reimplemented from homeassistant.components.unifiprotect.entity.ProtectEntityDescription.

Definition at line 69 of file sensor.py.

◆ _rounded_value()

Any homeassistant.components.unifiprotect.sensor.ProtectSensorEntityDescription._rounded_value (   self,
int  precision,
Callable[[T], Any]  getter,
obj 
)
private
Round value to precision if set.

Definition at line 79 of file sensor.py.

Member Data Documentation

◆ None

homeassistant.components.unifiprotect.sensor.ProtectSensorEntityDescription.None
static

Definition at line 67 of file sensor.py.


The documentation for this class was generated from the following file: