1 """Demo platform that offers a fake Date entity."""
3 from __future__
import annotations
5 from datetime
import date
18 config_entry: ConfigEntry,
19 async_add_entities: AddEntitiesCallback,
21 """Set up the demo date platform."""
36 """Representation of a Demo date entity."""
38 _attr_has_entity_name =
True
40 _attr_should_poll =
False
50 """Initialize the Demo date entity."""
57 identifiers={(DOMAIN, unique_id)}, name=device_name
61 """Update the date."""
None async_set_value(self, date value)
None __init__(self, str unique_id, str device_name, date state, str icon, bool assumed_state)
None async_write_ha_state(self)
None async_setup_entry(HomeAssistant hass, ConfigEntry config_entry, AddEntitiesCallback async_add_entities)