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

Classes

class  TriggerWeatherEntity
 
class  WeatherExtraStoredData
 
class  WeatherTemplate
 

Functions

None async_setup_platform (HomeAssistant hass, ConfigType config, AddEntitiesCallback async_add_entities, DiscoveryInfoType|None discovery_info=None)
 

Variables

tuple CHECK_FORECAST_KEYS
 
dictionary CONDITION_CLASSES
 
string CONF_APPARENT_TEMPERATURE_TEMPLATE = "apparent_temperature_template"
 
string CONF_ATTRIBUTION_TEMPLATE = "attribution_template"
 
string CONF_CLOUD_COVERAGE_TEMPLATE = "cloud_coverage_template"
 
string CONF_CONDITION_TEMPLATE = "condition_template"
 
string CONF_DEW_POINT_TEMPLATE = "dew_point_template"
 
string CONF_FORECAST_DAILY_TEMPLATE = "forecast_daily_template"
 
string CONF_FORECAST_HOURLY_TEMPLATE = "forecast_hourly_template"
 
string CONF_FORECAST_TWICE_DAILY_TEMPLATE = "forecast_twice_daily_template"
 
string CONF_HUMIDITY_TEMPLATE = "humidity_template"
 
string CONF_OZONE_TEMPLATE = "ozone_template"
 
string CONF_PRECIPITATION_UNIT = "precipitation_unit"
 
string CONF_PRESSURE_TEMPLATE = "pressure_template"
 
string CONF_PRESSURE_UNIT = "pressure_unit"
 
string CONF_TEMPERATURE_TEMPLATE = "temperature_template"
 
string CONF_VISIBILITY_TEMPLATE = "visibility_template"
 
string CONF_VISIBILITY_UNIT = "visibility_unit"
 
string CONF_WEATHER = "weather"
 
string CONF_WIND_BEARING_TEMPLATE = "wind_bearing_template"
 
string CONF_WIND_GUST_SPEED_TEMPLATE = "wind_gust_speed_template"
 
string CONF_WIND_SPEED_TEMPLATE = "wind_speed_template"
 
string CONF_WIND_SPEED_UNIT = "wind_speed_unit"
 
 PLATFORM_SCHEMA = WEATHER_PLATFORM_SCHEMA.extend(WEATHER_SCHEMA.schema)
 
 WEATHER_SCHEMA
 

Detailed Description

Template platform that aggregates meteorological data.

Function Documentation

◆ async_setup_platform()

None homeassistant.components.template.weather.async_setup_platform ( HomeAssistant  hass,
ConfigType  config,
AddEntitiesCallback  async_add_entities,
DiscoveryInfoType | None   discovery_info = None 
)
Set up the Template weather.

Definition at line 138 of file weather.py.

Variable Documentation

◆ CHECK_FORECAST_KEYS

tuple homeassistant.components.template.weather.CHECK_FORECAST_KEYS
Initial value:
1 = (
2  set()
3  .union(Forecast.__annotations__.keys())
4  # Manually add the forecast resulting attributes that only exists
5  # as native_* in the Forecast definition
6  .union(("apparent_temperature", "wind_gust_speed", "dew_point"))
7 )

Definition at line 59 of file weather.py.

◆ CONDITION_CLASSES

dictionary homeassistant.components.template.weather.CONDITION_CLASSES
Initial value:
1 = {
2  ATTR_CONDITION_CLEAR_NIGHT,
3  ATTR_CONDITION_CLOUDY,
4  ATTR_CONDITION_FOG,
5  ATTR_CONDITION_HAIL,
6  ATTR_CONDITION_LIGHTNING,
7  ATTR_CONDITION_LIGHTNING_RAINY,
8  ATTR_CONDITION_PARTLYCLOUDY,
9  ATTR_CONDITION_POURING,
10  ATTR_CONDITION_RAINY,
11  ATTR_CONDITION_SNOWY,
12  ATTR_CONDITION_SNOWY_RAINY,
13  ATTR_CONDITION_SUNNY,
14  ATTR_CONDITION_WINDY,
15  ATTR_CONDITION_WINDY_VARIANT,
16  ATTR_CONDITION_EXCEPTIONAL,
17 }

Definition at line 67 of file weather.py.

◆ CONF_APPARENT_TEMPERATURE_TEMPLATE

string homeassistant.components.template.weather.CONF_APPARENT_TEMPERATURE_TEMPLATE = "apparent_temperature_template"

Definition at line 105 of file weather.py.

◆ CONF_ATTRIBUTION_TEMPLATE

string homeassistant.components.template.weather.CONF_ATTRIBUTION_TEMPLATE = "attribution_template"

Definition at line 89 of file weather.py.

◆ CONF_CLOUD_COVERAGE_TEMPLATE

string homeassistant.components.template.weather.CONF_CLOUD_COVERAGE_TEMPLATE = "cloud_coverage_template"

Definition at line 103 of file weather.py.

◆ CONF_CONDITION_TEMPLATE

string homeassistant.components.template.weather.CONF_CONDITION_TEMPLATE = "condition_template"

Definition at line 88 of file weather.py.

◆ CONF_DEW_POINT_TEMPLATE

string homeassistant.components.template.weather.CONF_DEW_POINT_TEMPLATE = "dew_point_template"

Definition at line 104 of file weather.py.

◆ CONF_FORECAST_DAILY_TEMPLATE

string homeassistant.components.template.weather.CONF_FORECAST_DAILY_TEMPLATE = "forecast_daily_template"

Definition at line 95 of file weather.py.

◆ CONF_FORECAST_HOURLY_TEMPLATE

string homeassistant.components.template.weather.CONF_FORECAST_HOURLY_TEMPLATE = "forecast_hourly_template"

Definition at line 96 of file weather.py.

◆ CONF_FORECAST_TWICE_DAILY_TEMPLATE

string homeassistant.components.template.weather.CONF_FORECAST_TWICE_DAILY_TEMPLATE = "forecast_twice_daily_template"

Definition at line 97 of file weather.py.

◆ CONF_HUMIDITY_TEMPLATE

string homeassistant.components.template.weather.CONF_HUMIDITY_TEMPLATE = "humidity_template"

Definition at line 87 of file weather.py.

◆ CONF_OZONE_TEMPLATE

string homeassistant.components.template.weather.CONF_OZONE_TEMPLATE = "ozone_template"

Definition at line 93 of file weather.py.

◆ CONF_PRECIPITATION_UNIT

string homeassistant.components.template.weather.CONF_PRECIPITATION_UNIT = "precipitation_unit"

Definition at line 101 of file weather.py.

◆ CONF_PRESSURE_TEMPLATE

string homeassistant.components.template.weather.CONF_PRESSURE_TEMPLATE = "pressure_template"

Definition at line 90 of file weather.py.

◆ CONF_PRESSURE_UNIT

string homeassistant.components.template.weather.CONF_PRESSURE_UNIT = "pressure_unit"

Definition at line 98 of file weather.py.

◆ CONF_TEMPERATURE_TEMPLATE

string homeassistant.components.template.weather.CONF_TEMPERATURE_TEMPLATE = "temperature_template"

Definition at line 86 of file weather.py.

◆ CONF_VISIBILITY_TEMPLATE

string homeassistant.components.template.weather.CONF_VISIBILITY_TEMPLATE = "visibility_template"

Definition at line 94 of file weather.py.

◆ CONF_VISIBILITY_UNIT

string homeassistant.components.template.weather.CONF_VISIBILITY_UNIT = "visibility_unit"

Definition at line 100 of file weather.py.

◆ CONF_WEATHER

string homeassistant.components.template.weather.CONF_WEATHER = "weather"

Definition at line 85 of file weather.py.

◆ CONF_WIND_BEARING_TEMPLATE

string homeassistant.components.template.weather.CONF_WIND_BEARING_TEMPLATE = "wind_bearing_template"

Definition at line 92 of file weather.py.

◆ CONF_WIND_GUST_SPEED_TEMPLATE

string homeassistant.components.template.weather.CONF_WIND_GUST_SPEED_TEMPLATE = "wind_gust_speed_template"

Definition at line 102 of file weather.py.

◆ CONF_WIND_SPEED_TEMPLATE

string homeassistant.components.template.weather.CONF_WIND_SPEED_TEMPLATE = "wind_speed_template"

Definition at line 91 of file weather.py.

◆ CONF_WIND_SPEED_UNIT

string homeassistant.components.template.weather.CONF_WIND_SPEED_UNIT = "wind_speed_unit"

Definition at line 99 of file weather.py.

◆ PLATFORM_SCHEMA

homeassistant.components.template.weather.PLATFORM_SCHEMA = WEATHER_PLATFORM_SCHEMA.extend(WEATHER_SCHEMA.schema)

Definition at line 135 of file weather.py.

◆ WEATHER_SCHEMA

homeassistant.components.template.weather.WEATHER_SCHEMA
Initial value:
1 = vol.Schema(
2  {
3  vol.Required(CONF_NAME): cv.template,
4  vol.Required(CONF_CONDITION_TEMPLATE): cv.template,
5  vol.Required(CONF_TEMPERATURE_TEMPLATE): cv.template,
6  vol.Required(CONF_HUMIDITY_TEMPLATE): cv.template,
7  vol.Optional(CONF_ATTRIBUTION_TEMPLATE): cv.template,
8  vol.Optional(CONF_PRESSURE_TEMPLATE): cv.template,
9  vol.Optional(CONF_WIND_SPEED_TEMPLATE): cv.template,
10  vol.Optional(CONF_WIND_BEARING_TEMPLATE): cv.template,
11  vol.Optional(CONF_OZONE_TEMPLATE): cv.template,
12  vol.Optional(CONF_VISIBILITY_TEMPLATE): cv.template,
13  vol.Optional(CONF_FORECAST_DAILY_TEMPLATE): cv.template,
14  vol.Optional(CONF_FORECAST_HOURLY_TEMPLATE): cv.template,
15  vol.Optional(CONF_FORECAST_TWICE_DAILY_TEMPLATE): cv.template,
16  vol.Optional(CONF_UNIQUE_ID): cv.string,
17  vol.Optional(CONF_TEMPERATURE_UNIT): vol.In(TemperatureConverter.VALID_UNITS),
18  vol.Optional(CONF_PRESSURE_UNIT): vol.In(PressureConverter.VALID_UNITS),
19  vol.Optional(CONF_WIND_SPEED_UNIT): vol.In(SpeedConverter.VALID_UNITS),
20  vol.Optional(CONF_VISIBILITY_UNIT): vol.In(DistanceConverter.VALID_UNITS),
21  vol.Optional(CONF_PRECIPITATION_UNIT): vol.In(DistanceConverter.VALID_UNITS),
22  vol.Optional(CONF_WIND_GUST_SPEED_TEMPLATE): cv.template,
23  vol.Optional(CONF_CLOUD_COVERAGE_TEMPLATE): cv.template,
24  vol.Optional(CONF_DEW_POINT_TEMPLATE): cv.template,
25  vol.Optional(CONF_APPARENT_TEMPERATURE_TEMPLATE): cv.template,
26  }
27 )

Definition at line 107 of file weather.py.