| 
    ESPHome 2025.10.3
    
   | 
 
#include <automation.h>
Public Member Functions | |
| TemplatableValue () | |
| template<typename F , enable_if_t<!is_invocable< F, X... >::value, int > = 0> | |
| TemplatableValue (F value) | |
| template<typename F , enable_if_t< is_invocable< F, X... >::value, int > = 0> | |
| TemplatableValue (F f) | |
| TemplatableValue (const TemplatableValue &other) | |
| TemplatableValue (TemplatableValue &&other) noexcept | |
| TemplatableValue & | operator= (const TemplatableValue &other) | 
| TemplatableValue & | operator= (TemplatableValue &&other) noexcept | 
| ~TemplatableValue () | |
| bool | has_value () | 
| T | value (X... x) | 
| optional< T > | optional_value (X... x) | 
| T | value_or (X... x, T default_value) | 
Protected Types | |
| enum | : uint8_t { NONE , VALUE , LAMBDA } | 
Protected Attributes | ||
| enum esphome::TemplatableValue:: { ... } | type_ | |
| union { | ||
| T value_ | ||
| std::function< T(X...)> * f_ | ||
| }; | ||
Definition at line 26 of file automation.h.
      
  | 
  protected | 
| Enumerator | |
|---|---|
| NONE | |
| VALUE | |
| LAMBDA | |
Definition at line 108 of file automation.h.
      
  | 
  inline | 
Definition at line 28 of file automation.h.
      
  | 
  inline | 
Definition at line 30 of file automation.h.
      
  | 
  inline | 
Definition at line 34 of file automation.h.
      
  | 
  inline | 
Definition at line 39 of file automation.h.
      
  | 
  inlinenoexcept | 
Definition at line 48 of file automation.h.
      
  | 
  inline | 
Definition at line 75 of file automation.h.
      
  | 
  inline | 
Definition at line 83 of file automation.h.
      
  | 
  inline | 
Definition at line 59 of file automation.h.
      
  | 
  inlinenoexcept | 
Definition at line 67 of file automation.h.
      
  | 
  inline | 
Definition at line 93 of file automation.h.
      
  | 
  inline | 
Definition at line 85 of file automation.h.
      
  | 
  inline | 
Definition at line 100 of file automation.h.
| union { ... } esphome::TemplatableValue< T, X > | 
| std::function<T(X...)>* esphome::TemplatableValue< T, X >::f_ | 
Definition at line 116 of file automation.h.
| enum { ... } esphome::TemplatableValue< T, X >::type_ | 
| T esphome::TemplatableValue< T, X >::value_ | 
Definition at line 115 of file automation.h.