Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.template.helpers Namespace Reference

Functions

bool _blueprint_in_use (HomeAssistant hass, str blueprint_path)
 
None _reload_blueprint_templates (HomeAssistant hass, str blueprint_path)
 
blueprint.DomainBlueprints async_get_blueprints (HomeAssistant hass)
 
str|None blueprint_in_template (HomeAssistant hass, str entity_id)
 
list[str] templates_with_blueprint (HomeAssistant hass, str blueprint_path)
 

Variables

string DATA_BLUEPRINTS = "template_blueprints"
 
 LOGGER = logging.getLogger(__name__)
 

Detailed Description

Helpers for template integration.

Function Documentation

◆ _blueprint_in_use()

bool homeassistant.components.template.helpers._blueprint_in_use ( HomeAssistant  hass,
str  blueprint_path 
)
private
Return True if any template references the blueprint.

Definition at line 42 of file helpers.py.

◆ _reload_blueprint_templates()

None homeassistant.components.template.helpers._reload_blueprint_templates ( HomeAssistant  hass,
str  blueprint_path 
)
private
Reload all templates that rely on a specific blueprint.

Definition at line 47 of file helpers.py.

◆ async_get_blueprints()

blueprint.DomainBlueprints homeassistant.components.template.helpers.async_get_blueprints ( HomeAssistant  hass)
Get template blueprints.

Definition at line 54 of file helpers.py.

◆ blueprint_in_template()

str | None homeassistant.components.template.helpers.blueprint_in_template ( HomeAssistant  hass,
str  entity_id 
)
Return the blueprint the template entity is based on or None.

Definition at line 32 of file helpers.py.

◆ templates_with_blueprint()

list[str] homeassistant.components.template.helpers.templates_with_blueprint ( HomeAssistant  hass,
str  blueprint_path 
)
Return all template entity ids that reference the blueprint.

Definition at line 20 of file helpers.py.

Variable Documentation

◆ DATA_BLUEPRINTS

string homeassistant.components.template.helpers.DATA_BLUEPRINTS = "template_blueprints"

Definition at line 14 of file helpers.py.

◆ LOGGER

homeassistant.components.template.helpers.LOGGER = logging.getLogger(__name__)

Definition at line 16 of file helpers.py.