CHSM  4.4.1
Public Member Functions | List of all members
CHSM::event Class Reference

The occurrence of an event ("broadcast") is that which causes transitions in a machine. More...

#include <chsm.h>

Public Member Functions

 event (CHSM_EVENT_ARGS)
 Construct an event. More...
 
template<typename EventClass >
bool is_type () const
 Checks whether this event is of a particular event type. More...
 
char const * name () const
 Returns the name of this event. More...
 
void operator() ()
 Broadcast an event to a machine. More...
 
virtual ~event ()
 Destroy an event. More...
 

Detailed Description

The occurrence of an event ("broadcast") is that which causes transitions in a machine.

An event has a name, may optionally be derived from another, and may optionally have parameters during a broadcast.

Author
Paul J. Lucas

Constructor & Destructor Documentation

CHSM::event::event ( CHSM_EVENT_ARGS  )

Construct an event.

CHSM::event::~event ( )
virtual

Destroy an event.

Member Function Documentation

template<typename EventClass >
bool CHSM::event::is_type ( ) const
inline

Checks whether this event is of a particular event type.

This function is a convenient shorthand.

Template Parameters
EventClassThe event class's type.
Returns
Returns true only if this event is of the given type.
char const* CHSM::event::name ( ) const
inline

Returns the name of this event.

Returns
Returns said name.
void CHSM::event::operator() ( )
inline

Broadcast an event to a machine.

If it has a precondition, it will be evaluated first. Actions may be performed and transitions may occur.


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