51 template <
class EventTypeConditionNotFulfilled = EvCounterNotFulfilled,
52 class EventTypeConditionFulfilled = EvCounterFulfilled>
55 CounterStateTemplate<EventTypeConditionNotFulfilled, EventTypeConditionFulfilled>>
78 this->
getContext()->systemObserverPrx->incrementCounter(
81 notFullfilled,
"Counter maximum not reached");
83 "Counter maximum reached");
96 ConditionIdentifier cond1, cond2;
#define DEFINEEVENT(NEWEVENT)
this macro declares a new event-class derived vom Event, to have a compiletime check for typos in eve...
Literals are part of the user front end of the ArmarX condition mechanism.
static VarList createParameterList()
Static helper method to create an empty parameterlist.
ContextType * getContext() const
void removeCondition(ConditionIdentifier conditionId)
Utility function to remove an installed condition on the distributed conditionhandler.
ConditionIdentifier installCondition(const Term &condition, const EventPtr evt, const std::string &desc="")
Utility function to install a condition on the distributed conditionhandler.
void setOutput(std::string const &key, const Variant &value)
setOuput() sets an output parameter of this state.
bool addToInput(const std::string &key, const ContainerType &type, bool optional, VariantContainerBasePtr defaultValue=VariantContainerBasePtr())
Adds a key,type-pair to the input parameters.
std::enable_if_t< std::is_base_of_v< VariantDataClass, T >, IceInternal::Handle< T > > getInput(const std::string &key) const
getInput can be used to access a specific input parameter.
bool addToOutput(const std::string &key, VariantTypeId type, bool optional)
Adds a key,type-pair to the output parameters.
CounterStateTemplate< EvCounterNotFulfilled, EvCounterFulfilled > CounterState
CounterState is a typedef for the CounterStateTemplate, that uses the events EvCounterNotFulfilled an...
const VariantTypeId ChannelRef
This file offers overloads of toIce() and fromIce() functions for STL container types.
IceInternal::Handle< DataFieldIdentifier > DataFieldIdentifierPtr
Typedef of DataFieldIdentifierPtr as IceInternal::Handle<DataFieldIdentifier> for convenience.
Stateimplementation, that increments a given counter by one on the SystemObserver and installs 2 cond...
void onEnter()
Virtual function, in which the behaviour of state is defined, when it is entered. Can be overridden,...
void defineParameters()
Virtual function, in which input/local/output parameters can be specified.
void onExit()
Virtual function, in which the behaviour of state is defined, when it is exited. Can be overridden,...