Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.guardian.valve Namespace Reference

Classes

class  GuardianValveState
 
class  ValveControllerValve
 
class  ValveControllerValveDescription
 

Functions

None async_close_valve (Client client)
 
None async_halt_valve (Client client)
 
None async_open_valve (Client client)
 
None async_setup_entry (HomeAssistant hass, ConfigEntry entry, AddEntitiesCallback async_add_entities)
 
bool is_closing (dict[str, Any] data)
 
bool is_opening (dict[str, Any] data)
 

Variables

tuple VALVE_CONTROLLER_DESCRIPTIONS
 
string VALVE_KIND_VALVE = "valve"
 

Detailed Description

Valves for the Elexa Guardian integration.

Function Documentation

◆ async_close_valve()

None homeassistant.components.guardian.valve.async_close_valve ( Client  client)
Close the valve.

Definition at line 57 of file valve.py.

◆ async_halt_valve()

None homeassistant.components.guardian.valve.async_halt_valve ( Client  client)
Halt the valve.

Definition at line 63 of file valve.py.

◆ async_open_valve()

None homeassistant.components.guardian.valve.async_open_valve ( Client  client)
Open the valve.

Definition at line 69 of file valve.py.

◆ async_setup_entry()

None homeassistant.components.guardian.valve.async_setup_entry ( HomeAssistant  hass,
ConfigEntry  entry,
AddEntitiesCallback   async_add_entities 
)
Set up Guardian switches based on a config entry.

Definition at line 111 of file valve.py.

◆ is_closing()

bool homeassistant.components.guardian.valve.is_closing ( dict[str, Any]  data)
Return if the valve is closing.

Definition at line 76 of file valve.py.

◆ is_opening()

bool homeassistant.components.guardian.valve.is_opening ( dict[str, Any]  data)
Return if the valve is opening.

Definition at line 86 of file valve.py.

Variable Documentation

◆ VALVE_CONTROLLER_DESCRIPTIONS

tuple homeassistant.components.guardian.valve.VALVE_CONTROLLER_DESCRIPTIONS
Initial value:
1 = (
2  ValveControllerValveDescription(
3  key=VALVE_KIND_VALVE,
4  translation_key="valve_controller",
5  device_class=ValveDeviceClass.WATER,
6  api_category=API_VALVE_STATUS,
7  is_closed_fn=lambda data: data["state"] == GuardianValveState.CLOSED,
8  is_closing_fn=is_closing,
9  is_opening_fn=is_opening,
10  close_coro_fn=async_close_valve,
11  halt_coro_fn=async_halt_valve,
12  open_coro_fn=async_open_valve,
13  ),
14 )

Definition at line 95 of file valve.py.

◆ VALVE_KIND_VALVE

string homeassistant.components.guardian.valve.VALVE_KIND_VALVE = "valve"

Definition at line 27 of file valve.py.