homeassistant/components/sensibo/switch.py
async def async_setup_entry(
    hass: HomeAssistant, entry: ConfigEntry, async_add_entities: AddEntitiesCallback
) -> None:
    """Set up Sensibo binary sensor platform."""

    coordinator: SensiboDataUpdateCoordinator = hass.data[DOMAIN][entry.entry_id]

    entities: list[SensiboDeviceSwitch] = []

    entities.extend(
        SensiboDeviceSwitch(coordinator, device_id, description)
        for description in DEVICE_SWITCH_TYPES
        for device_id, device_data in coordinator.data.parsed.items()
        if device_data.model != "pure"
    )

    async_add_entities(entities)
Set up Sensibo binary sensor platform.
Set up Sensibo binary sensor platform.
Set up Sensibo binary sensor platform .
async def async_setup_entry(
    hass: HomeAssistant, entry: ConfigEntry, async_add_entities: AddEntitiesCallback
) -> None:
    coordinator: SensiboDataUpdateCoordinator = hass.data[DOMAIN][entry.entry_id]
    entities: list[SensiboDeviceSwitch] = []
    entities.extend(
        SensiboDeviceSwitch(coordinator, device_id, description)
        for description in DEVICE_SWITCH_TYPES
        for device_id, device_data in coordinator.data.parsed.items()
        if device_data.model != "pure"
    )
    async_add_entities(entities)
async def async_setup_entry ( hass : HomeAssistant , entry : ConfigEntry , async_add_entities : AddEntitiesCallback ) -> None : coordinator : SensiboDataUpdateCoordinator = hass . data [ DOMAIN ] [ entry . entry_id ] entities : list [ SensiboDeviceSwitch ] = [ ] entities . extend ( SensiboDeviceSwitch ( coordinator , device_id , description ) for description in DEVICE_SWITCH_TYPES for device_id , device_data in coordinator . data . parsed . items ( ) if device_data . model != "pure" ) async_add_entities ( entities )
Set up Sensibo binary sensor platform.
Set up Sensibo binary sensor platform .
"""Set up Sensibo binary sensor platform."""
hass
HomeAssistant
entry
ConfigEntry
async_add_entities
AddEntitiesCallback