OpenRTM-aist 2.0.2
Loading...
Searching...
No Matches
Macho.h File Reference
#include <new>
#include <cassert>
Include dependency graph for Macho.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  CheckSameType< T, U >
 
struct  CheckSameType< T, T >
 
class  Macho::_EmptyBox
 
struct  Macho::_KeyData
 
class  Macho::_StateSpecification
 
class  Macho::TopBase< T >
 
class  Macho::Link< C, P >
 
class  Macho::StateID< S >
 
class  Macho::_StateInstance
 
class  Macho::_RootInstance
 
class  Macho::_SubstateInstance< S >
 
class  Macho::_IEventBase
 
class  Macho::IEvent< TOP >
 
class  Macho::_Event6< TOP, R, P1, P2, P3, P4, P5, P6 >
 
class  Macho::_Event5< TOP, R, P1, P2, P3, P4, P5 >
 
class  Macho::_Event4< TOP, R, P1, P2, P3, P4 >
 
class  Macho::_Event3< TOP, R, P1, P2, P3 >
 
class  Macho::_Event2< TOP, R, P1, P2 >
 
class  Macho::_Event1< TOP, R, P1 >
 
class  Macho::_Event0< TOP, R >
 
class  _VS8_Bug_101615
 
class  Macho::_Initializer
 
class  Macho::_StaticInitializer
 
class  Macho::_DefaultInitializer
 
class  Macho::_HistoryInitializer
 
class  Macho::_AdaptingInitializer
 
class  Macho::_Initializer1< S, P1 >
 
class  Macho::_Initializer2< S, P1, P2 >
 
class  Macho::_Initializer3< S, P1, P2, P3 >
 
class  Macho::_Initializer4< S, P1, P2, P3, P4 >
 
class  Macho::_Initializer5< S, P1, P2, P3, P4, P5 >
 
class  Macho::_Initializer6< S, P1, P2, P3, P4, P5, P6 >
 
class  Macho::_MachineBase
 
class  Macho::Alias
 
class  Macho::Machine< TOP >
 
struct  Macho::Machine< TOP >::AfterAdvice
 

Namespaces

namespace  Macho
 

Macros

#define TOPSTATE(TOP)    struct TOP : public ::Macho::Link< TOP, ::Macho::TopBase< TOP > >
 
#define SUBSTATE(STATE, SUPERSTATE)    struct STATE : public ::Macho::Link< STATE, SUPERSTATE >
 
#define STATE(S)
 
#define DEEPHISTORY()
 
#define HISTORY()
 
#define PERSISTENT()
 

Typedefs

using Macho::Key = void*
 
using Macho::ID = unsigned int
 
using Macho::StateAlias = Alias
 

Functions

template<class B >
void * Macho::_createBox (void *&place)
 
template<class B >
void Macho::_deleteBox (void *&box, void *&place)
 
template<>
void * Macho::_createBox< _EmptyBox > (void *&place)
 
template<>
void Macho::_deleteBox< _EmptyBox > (void *&box, void *&place)
 
template<class TOP , class R , class P1 , class P2 , class P3 , class P4 , class P5 , class P6 >
IEvent< TOP > * Macho::Event (R(TOP::*handler)(P1, P2, P3, P4, P5, P6), const P1 &p1, const P2 &p2, const P3 &p3, const P4 &p4, const P5 &p5, const P6 &p6)
 
template<class TOP , class R , class P1 , class P2 , class P3 , class P4 , class P5 >
IEvent< TOP > * Macho::Event (R(TOP::*handler)(P1, P2, P3, P4, P5), const P1 &p1, const P2 &p2, const P3 &p3, const P4 &p4, const P5 &p5)
 
template<class TOP , class R , class P1 , class P2 , class P3 , class P4 >
IEvent< TOP > * Macho::Event (R(TOP::*handler)(P1, P2, P3, P4), const P1 &p1, const P2 &p2, const P3 &p3, const P4 &p4)
 
template<class TOP , class R , class P1 , class P2 , class P3 >
IEvent< TOP > * Macho::Event (R(TOP::*handler)(P1, P2, P3), const P1 &p1, const P2 &p2, const P3 &p3)
 
template<class TOP , class R , class P1 , class P2 >
IEvent< TOP > * Macho::Event (R(TOP::*handler)(P1, P2), const P1 &p1, const P2 &p2)
 
template<class TOP , class R , class P1 >
IEvent< TOP > * Macho::Event (R(TOP::*handler)(P1), const P1 &p1)
 
template<class TOP , class R >
IEvent< TOP > * Macho::Event (R(TOP::*handler)())
 
template<class S >
Alias Macho::State ()
 
template<class S , class P1 >
Alias Macho::State (const P1 &p1)
 
template<class S , class P1 , class P2 >
Alias Macho::State (const P1 &p1, const P2 &p2)
 
template<class S , class P1 , class P2 , class P3 >
Alias Macho::State (const P1 &p1, const P2 &p2, const P3 &p3)
 
template<class S , class P1 , class P2 , class P3 , class P4 >
Alias Macho::State (const P1 &p1, const P2 &p2, const P3 &p3, const P4 &p4)
 
template<class S , class P1 , class P2 , class P3 , class P4 , class P5 >
Alias Macho::State (const P1 &p1, const P2 &p2, const P3 &p3, const P4 &p4, const P5 &p5)
 
template<class S , class P1 , class P2 , class P3 , class P4 , class P5 , class P6 >
Alias Macho::State (const P1 &p1, const P2 &p2, const P3 &p3, const P4 &p4, const P5 &p5, const P6 &p6)
 
template<class S >
Alias Macho::StateHistory (const _MachineBase &machine)
 

Variables

static _DefaultInitializer Macho::_theDefaultInitializer
 
static _HistoryInitializer Macho::_theHistoryInitializer
 

Macro Definition Documentation

◆ DEEPHISTORY

#define DEEPHISTORY ( )
Value:
private: \
/* If no superstate has history, SUPER::_setHistorySuper is a NOOP */ \
void _saveHistory(::Macho::_StateInstance & self, ::Macho::_StateInstance & /* shallow */, ::Macho::_StateInstance & deep) override\
{ self.setHistory(&deep); SELF::SUPER::_setHistorySuper(self, deep); } \
protected: \
/* Substates may use _setHistorySuper to bubble up history */ \
void _setHistorySuper(::Macho::_StateInstance & self, ::Macho::_StateInstance & deep) override\
{ self.setHistorySuper(deep); } \
public:\
static_assert(true, "dummy for extra semicolon warning")
Definition Macho.h:629

◆ HISTORY

#define HISTORY ( )
Value:
private: \
/* If no superstate has history, SUPER::_setHistorySuper is a NOOP */ \
virtual void _saveHistory(::Macho::_StateInstance & self, ::Macho::_StateInstance & shallow, ::Macho::_StateInstance & deep) \
{ self.setHistory(&shallow); SELF::SUPER::_setHistorySuper(self, deep); } \
protected: \
/* Substates may use _setHistorySuper to bubble up history */ \
virtual void _setHistorySuper(::Macho::_StateInstance & self, ::Macho::_StateInstance & deep) \
{ self.setHistorySuper(deep); } \
public:\
static_assert(true, "dummy for extra semicolon warning")

◆ PERSISTENT

#define PERSISTENT ( )
Value:
private: \
virtual void _deleteBox(::Macho::_StateInstance & instance) {} \
public:

◆ STATE

#define STATE ( S)
Value:
public: \
using SELF = S; \
/* Constructor and destructor already defined: you can't (and shouldn't) have your own! */ \
/* For the user a state class "constructor" and "destructor" are its entry and exit method! */ \
S(::Macho::_StateInstance & instance) : ::Macho::Link<S, SUPER>(instance) { \
/* Compile time check: S must derive directly from Link<S, SUPER> */ \
using MustDeriveFromLink = ::CheckSameType< ::Macho::Link<S, SUPER>, LINK>::Check; \
} \
~S() {} \
static const char * _state_name() { return #S; } \
/* Get to your Box with this method: */ \
Box & box() { return *static_cast<Box *>(_box()); } \
friend class ::_VS8_Bug_101615;
Definition Macho.h:289
Definition Macho.h:214

◆ SUBSTATE

#define SUBSTATE ( STATE,
SUPERSTATE )    struct STATE : public ::Macho::Link< STATE, SUPERSTATE >

◆ TOPSTATE

#define TOPSTATE ( TOP)     struct TOP : public ::Macho::Link< TOP, ::Macho::TopBase< TOP > >