Home Assistant Unofficial Reference 2024.12.1
collection.py File Reference

Go to the source code of this file.

Classes

class  homeassistant.helpers.collection._CollectionLifeCycle
 
class  homeassistant.helpers.collection.CollectionChange
 
class  homeassistant.helpers.collection.CollectionEntity
 
class  homeassistant.helpers.collection.CollectionError
 
class  homeassistant.helpers.collection.DictStorageCollection
 
class  homeassistant.helpers.collection.DictStorageCollectionWebsocket
 
class  homeassistant.helpers.collection.IDLessCollection
 
class  homeassistant.helpers.collection.IDManager
 
class  homeassistant.helpers.collection.ItemNotFound
 
class  homeassistant.helpers.collection.ObservableCollection
 
class  homeassistant.helpers.collection.SerializedStorageCollection
 
class  homeassistant.helpers.collection.StorageCollection
 
class  homeassistant.helpers.collection.StorageCollectionWebsocket
 
class  homeassistant.helpers.collection.YamlCollection
 

Namespaces

 homeassistant.helpers.collection
 

Functions

None homeassistant.helpers.collection.__init__ (self, _StorageCollectionT storage_collection, str api_prefix, str model_name, VolDictType create_schema, VolDictType update_schema)
 
None homeassistant.helpers.collection.__init__ (self, Store[_StoreT] store, IDManager|None id_manager=None)
 
_StoreT|None homeassistant.helpers.collection._async_load_data (self)
 
None homeassistant.helpers.collection._async_schedule_save (self)
 
SerializedStorageCollection homeassistant.helpers.collection._base_data_to_save (self)
 
_ItemT homeassistant.helpers.collection._create_item (self, str item_id, dict data)
 
_StoreT homeassistant.helpers.collection._data_to_save (self)
 
_ItemT homeassistant.helpers.collection._deserialize_item (self, dict data)
 
str homeassistant.helpers.collection._get_suggested_id (self, dict info)
 
str homeassistant.helpers.collection._hash_item (self, dict item)
 
dict homeassistant.helpers.collection._process_create_data (self, dict data)
 
dict homeassistant.helpers.collection._serialize_item (self, str item_id, _ItemT item)
 
_ItemT homeassistant.helpers.collection._update_data (self, _ItemT item, dict update_data)
 
None homeassistant.helpers.collection._ws_subscribe (self, HomeAssistant hass, websocket_api.ActiveConnection connection, dict msg)
 
_ItemT homeassistant.helpers.collection.async_create_item (self, dict data)
 
None homeassistant.helpers.collection.async_delete_item (self, str item_id)
 
None homeassistant.helpers.collection.async_load (self)
 
None homeassistant.helpers.collection.async_setup (self, HomeAssistant hass)
 
_ItemT homeassistant.helpers.collection.async_update_item (self, str item_id, dict updates)
 
CollectionEntity homeassistant.helpers.collection.create_entity (type[CollectionEntity] entity_class, ConfigType config)
 
HomeAssistant homeassistant.helpers.collection.hass (self)
 
str homeassistant.helpers.collection.item_id_key (self)
 
None homeassistant.helpers.collection.sync_entity_lifecycle (HomeAssistant hass, str domain, str platform, EntityComponent[_EntityT] entity_component, StorageCollection|YamlCollection collection, type[CollectionEntity] entity_class)
 
None homeassistant.helpers.collection.ws_create_item (self, HomeAssistant hass, websocket_api.ActiveConnection connection, dict msg)
 
None homeassistant.helpers.collection.ws_delete_item (self, HomeAssistant hass, websocket_api.ActiveConnection connection, dict msg)
 
None homeassistant.helpers.collection.ws_list_item (self, HomeAssistant hass, websocket_api.ActiveConnection connection, dict msg)
 
None homeassistant.helpers.collection.ws_update_item (self, HomeAssistant hass, websocket_api.ActiveConnection connection, dict msg)
 

Variables

 homeassistant.helpers.collection._EntityT = TypeVar("_EntityT", bound=Entity, default=Entity)
 
 homeassistant.helpers.collection._GROUP_BY_KEY = attrgetter("change_type")
 
 homeassistant.helpers.collection._remove_subscription
 
 homeassistant.helpers.collection.api_prefix
 
string homeassistant.helpers.collection.CHANGE_ADDED = "added"
 
string homeassistant.helpers.collection.CHANGE_REMOVED = "removed"
 
string homeassistant.helpers.collection.CHANGE_UPDATED = "updated"
 
 homeassistant.helpers.collection.ChangeListener
 
 homeassistant.helpers.collection.ChangeSetListener
 
 homeassistant.helpers.collection.create_schema
 
 homeassistant.helpers.collection.model_name
 
int homeassistant.helpers.collection.SAVE_DELAY = 10
 
 homeassistant.helpers.collection.storage_collection
 
int homeassistant.helpers.collection.STORAGE_VERSION = 1
 
 homeassistant.helpers.collection.store
 
 homeassistant.helpers.collection.update_schema