|
Symmetri
|
Callback is a wrapper around any type that you to tie to a transition. Typically this is an invokable object, such as a function, that executes some side-effects, but it can by anything if you implement a fire function for it. The output can be used to communicate success or failure to the petri-net executor. You can create custom behavior by defining a tailored "Token fire(const A&)" for your class A. More...
#include <callback.h>
Public Member Functions | |
| template<typename Transition> | |
| Callback (Transition callback) | |
| Construct a new Callback object. | |
| template<typename T, typename... Args> | |
| Callback (identity< T >, Args &&...args) | |
| Callback (Callback &&f)=default | |
| Callback & | operator= (Callback &&other)=default |
| Callback (const Callback &o)=delete | |
| Callback & | operator= (const Callback &other)=delete |
| auto | getEndTime () const |
Friends | |
| Token | fire (const Callback &callback) |
| Eventlog | getLog (const Callback &callback) |
| bool | isSynchronous (const Callback &callback) |
| void | cancel (const Callback &callback) |
| void | pause (const Callback &callback) |
| void | resume (const Callback &callback) |
Callback is a wrapper around any type that you to tie to a transition. Typically this is an invokable object, such as a function, that executes some side-effects, but it can by anything if you implement a fire function for it. The output can be used to communicate success or failure to the petri-net executor. You can create custom behavior by defining a tailored "Token fire(const A&)" for your class A.
Random note, this class is inspired/taken by Sean Parents' talk "inheritance is the base class of evil".
|
inline |