ESPHome  1.15.2
Public Member Functions | Protected Member Functions | Protected Attributes
esphome::Action< Ts > Class Template Referenceabstract

#include <automation.h>

Public Member Functions

virtual void play_complex (Ts... x)
 
virtual void stop_complex ()
 
virtual bool is_running ()
 Check if this or any of the following actions are currently running. More...
 
int num_running_total ()
 The total number of actions that are currently running in this plus any of the following actions in the chain. More...
 

Protected Member Functions

virtual void play (Ts... x)=0
 
void play_next_ (Ts... x)
 
template<int... S>
void play_next_tuple_ (const std::tuple< Ts... > &tuple, seq< S... >)
 
void play_next_tuple_ (const std::tuple< Ts... > &tuple)
 
virtual void stop ()
 
void stop_next_ ()
 
bool is_running_next_ ()
 

Protected Attributes

friend ActionList< Ts... >
 
Action< Ts... > * next_ = nullptr
 
int num_running_ {0}
 The number of instances of this sequence in the list of actions that is currently being executed. More...
 

Detailed Description

template<typename... Ts>
class esphome::Action< Ts >

Definition at line 80 of file automation.h.

Member Function Documentation

◆ is_running()

template<typename... Ts>
virtual bool esphome::Action< Ts >::is_running ( )
inlinevirtual

Check if this or any of the following actions are currently running.

Definition at line 95 of file automation.h.

◆ is_running_next_()

template<typename... Ts>
bool esphome::Action< Ts >::is_running_next_ ( )
inlineprotected

Definition at line 132 of file automation.h.

◆ num_running_total()

template<typename... Ts>
int esphome::Action< Ts >::num_running_total ( )
inline

The total number of actions that are currently running in this plus any of the following actions in the chain.

Definition at line 99 of file automation.h.

◆ play()

template<typename... Ts>
virtual void esphome::Action< Ts >::play ( Ts...  x)
protectedpure virtual

Implemented in esphome::display::DisplayPageShowPrevAction< Ts >, esphome::display::DisplayPageShowNextAction< Ts >, esphome::remote_base::RemoteTransmitterActionBase< Ts >, esphome::remote_base::RemoteTransmitterActionBase< Ts... >, esphome::mqtt::MQTTPublishJsonAction< Ts >, esphome::UpdateComponentAction< Ts >, esphome::WaitUntilAction< Ts >, esphome::WhileAction< Ts >, esphome::IfAction< Ts >, esphome::light::AddressableSet< Ts >, esphome::script::ScriptWaitAction< Ts >, esphome::LambdaAction< Ts >, esphome::dfplayer::PlayFileAction< Ts >, esphome::DelayAction< Ts >, esphome::pid::PIDSetControlParametersAction< Ts >, esphome::pid::PIDResetIntegralTermAction< Ts >, esphome::deep_sleep::PreventDeepSleepAction< Ts >, esphome::script::ScriptStopAction< Ts >, esphome::deep_sleep::EnterDeepSleepAction< Ts >, esphome::rf_bridge::RFBridgeLearnAction< Ts >, esphome::script::ScriptExecuteAction< Ts >, esphome::pid::PIDAutotuneAction< Ts >, esphome::integration::ResetAction< Ts >, esphome::tm1651::TurnOffAction< Ts >, esphome::servo::ServoDetachAction< Ts >, esphome::http_request::HttpRequestSendAction< Ts >, esphome::tm1651::TurnOnAction< Ts >, esphome::rf_bridge::RFBridgeSendCodeAction< Ts >, esphome::stepper::SetSpeedAction< Ts >, esphome::light::DimRelativeAction< Ts >, esphome::rtttl::StopAction< Ts >, esphome::globals::GlobalVarSetAction< C, Ts >, esphome::mhz19::MHZ19ABCDisableAction< Ts >, esphome::mhz19::MHZ19ABCEnableAction< Ts >, esphome::ledc::SetFrequencyAction< Ts >, esphome::fan::ToggleAction< Ts >, esphome::esp8266_pwm::SetFrequencyAction< Ts >, esphome::mhz19::MHZ19CalibrateZeroAction< Ts >, esphome::fan::TurnOffAction< Ts >, esphome::cover::StopAction< Ts >, esphome::switch_::ToggleAction< Ts >, esphome::api::HomeAssistantServiceCallAction< Ts >, esphome::output::TurnOnAction< Ts >, esphome::cover::CloseAction< Ts >, esphome::switch_::TurnOffAction< Ts >, esphome::uart::UARTWriteAction< Ts >, esphome::fan::TurnOnAction< Ts >, esphome::output::TurnOffAction< Ts >, esphome::cover::OpenAction< Ts >, and esphome::switch_::TurnOnAction< Ts >.

◆ play_complex()

template<typename... Ts>
virtual void esphome::Action< Ts >::play_complex ( Ts...  x)
inlinevirtual

◆ play_next_()

template<typename... Ts>
void esphome::Action< Ts >::play_next_ ( Ts...  x)
inlineprotected

Definition at line 110 of file automation.h.

◆ play_next_tuple_() [1/2]

template<typename... Ts>
template<int... S>
void esphome::Action< Ts >::play_next_tuple_ ( const std::tuple< Ts... > &  tuple,
seq< S... >   
)
inlineprotected

Definition at line 118 of file automation.h.

◆ play_next_tuple_() [2/2]

template<typename... Ts>
void esphome::Action< Ts >::play_next_tuple_ ( const std::tuple< Ts... > &  tuple)
inlineprotected

Definition at line 121 of file automation.h.

◆ stop()

template<typename... Ts>
virtual void esphome::Action< Ts >::stop ( )
inlineprotectedvirtual

◆ stop_complex()

template<typename... Ts>
virtual void esphome::Action< Ts >::stop_complex ( )
inlinevirtual

Definition at line 87 of file automation.h.

◆ stop_next_()

template<typename... Ts>
void esphome::Action< Ts >::stop_next_ ( )
inlineprotected

Definition at line 126 of file automation.h.

Field Documentation

◆ ActionList< Ts... >

template<typename... Ts>
friend esphome::Action< Ts >::ActionList< Ts... >
protected

Definition at line 107 of file automation.h.

◆ next_

template<typename... Ts>
Action<Ts...>* esphome::Action< Ts >::next_ = nullptr
protected

Definition at line 138 of file automation.h.

◆ num_running_

template<typename... Ts>
int esphome::Action< Ts >::num_running_ {0}
protected

The number of instances of this sequence in the list of actions that is currently being executed.

Definition at line 142 of file automation.h.


The documentation for this class was generated from the following file: