1
0
mirror of https://github.com/home-assistant/core.git synced 2026-07-18 12:03:33 +01:00
Files
core/homeassistant/components/smlight/entity.py
T
TimL c24186e571 Add Bluetooth proxy support for SMLIGHT (#174710)
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: J. Nick Koston <nick@koston.org>
2026-06-29 15:12:49 +02:00

19 lines
612 B
Python

"""Base class for all SMLIGHT entities."""
from homeassistant.helpers.update_coordinator import CoordinatorEntity
from .coordinator import SmBaseDataUpdateCoordinator, base_device_info
class SmEntity(CoordinatorEntity[SmBaseDataUpdateCoordinator]):
"""Base class for all SMLight entities."""
_attr_has_entity_name = True
def __init__(self, coordinator: SmBaseDataUpdateCoordinator) -> None:
"""Initialize entity with device."""
super().__init__(coordinator)
self._attr_device_info = base_device_info(
coordinator.data.info, coordinator.client.host
)