$darkmode
#include <trigger.hpp>
Public Member Functions | |
| virtual ActionPtr | clone () const =0 |
| virtual void | operator() (const Sync &, TriggerRegistrar &)=0 |
| virtual bool | is_significant () const |
| virtual void | to_json (fable::Json &j) const =0 |
| Entity (std::string name) | |
| Entity (std::string name, std::string desc) | |
Public Member Functions inherited from cloe::Entity | |
| Entity (std::string name) | |
| Entity (std::string name, std::string desc) | |
| const std::string & | name () const |
| void | set_name (std::string name) |
| const std::string & | description () const |
| void | set_description (std::string desc) |
Protected Member Functions | |
| Logger | logger () const |
Friends | |
| void | to_json (fable::Json &j, const Action &a) |
Additional Inherited Members | |
Protected Attributes inherited from cloe::Entity | |
| std::string | name_ |
| std::string | desc_ |
Action represents the action portion of a trigger, and is what is executed when a trigger condition evaluates true.
It is created through an ActionFactory, and registered with the simulation through the Registrar interface.
The primary identifying interface of an Action is through it's constructor, where it receives its name, together with the to_json(fable::Json&) method, where any further state is represented. This allows a new identical Action to be created.
The execution is achieved through the function operator of the Action. Any further state required within the Action must be passed through the constructor of the Action.
|
pure virtual |
Clone this action with correct state information.
This happens when a sticky trigger evaluates to true.
Implemented in cloe::actions::SetVariableAction< T >, cloe::actions::PushRelease, cloe::actions::Insert, cloe::actions::Bundle, cloe::actions::Log, cloe::actions::Configure, cloe::utility::UseContact< D >, vtd::ScpAction, and engine::actions::Command.
|
inlinevirtual |
Return whether this action is a significant action.
All actions that have an effect on the result of a simulation are significant. Actions that are not significant are:
realtime_factor log
Insignificant actions are concealable, which removes them from the trigger history. This must be explicitly specified when inserting a trigger.
Reimplemented in cloe::actions::SetVariableAction< T >, cloe::actions::Bundle, cloe::actions::Log, and vtd::ScpAction.
|
inlineprotectedvirtual |
Return the Logger that the manager should use.
Reimplemented from cloe::Entity.
|
pure virtual |
Execute the action.
Implemented in cloe::actions::Insert, cloe::actions::Bundle, cloe::actions::SetVariableAction< T >, cloe::actions::PushRelease, cloe::actions::Log, cloe::actions::Configure, cloe::utility::UseContact< D >, vtd::ScpAction, and engine::actions::Command.
|
pure virtual |
Describe the action state so that the same action can be re-created through it's JSON representation with the corresponding ActionFactory.