INET Framework for OMNeT++/OMNEST
inet::Macho::_SubstateInstance< S > Class Template Reference

#include <Macho.h>

Inheritance diagram for inet::Macho::_SubstateInstance< S >:
inet::Macho::_StateInstance

Public Types

typedef S::Box Box
 

Public Member Functions

virtual ~_SubstateInstance ()
 
virtual const char * name () override
 
virtual ID id () override
 
virtual Key key () override
 
virtual _StateInstancecreate (_MachineBase &machine, _StateInstance *parent) override
 
virtual void createBox () override
 
virtual void deleteBox () override
 
- Public Member Functions inherited from inet::Macho::_StateInstance
virtual ~_StateInstance ()
 
void entry (_StateInstance &previous, bool first=true)
 
void exit (_StateInstance &next)
 
void init (bool history)
 
void saveHistory (_StateInstance &shallow, _StateInstance &deep)
 
void setHistorySuper (_StateInstance &deep)
 
void shutdown ()
 
void restore (_StateInstance &instance)
 
void setBox (void *box)
 
bool isChild (const _StateInstance &instance)
 
_StateSpecificationspecification ()
 
void * box ()
 
_MachineBasemachine ()
 
void setHistory (_StateInstance *history) const
 
_StateInstancehistory () const
 

Protected Member Functions

 _SubstateInstance (_MachineBase &machine, _StateInstance *parent)
 
- Protected Member Functions inherited from inet::Macho::_StateInstance
 _StateInstance (_MachineBase &machine, _StateInstance *parent)
 

Friends

template<class C , class P >
class MachoLink
 

Additional Inherited Members

- Protected Attributes inherited from inet::Macho::_StateInstance
_MachineBasemyMachine
 
_StateSpecificationmySpecification
 
_StateInstancemyHistory
 
_StateInstancemyParent
 
void * myBox
 
void * myBoxPlace
 

Member Typedef Documentation

template<class S>
typedef S::Box inet::Macho::_SubstateInstance< S >::Box

Constructor & Destructor Documentation

template<class S>
inet::Macho::_SubstateInstance< S >::_SubstateInstance ( _MachineBase machine,
_StateInstance parent 
)
inlineprotected
878  : _StateInstance(machine, parent)
879  {
880  assert(parent);
881  this->mySpecification = new S(*this);
882  }
_StateSpecification * mySpecification
Definition: Macho.h:822
_MachineBase & machine()
Definition: Macho.h:804
compose< A, pow< V,-1 > > S
Definition: Units.h:778
_StateInstance(_MachineBase &machine, _StateInstance *parent)
Definition: Macho.cc:121
template<class S>
virtual inet::Macho::_SubstateInstance< S >::~_SubstateInstance ( )
inlinevirtual
888  {
889  if (this->myBox)
890  Macho::_deleteBox<Box>(myBox, myBoxPlace);
891  }
void * myBox
Definition: Macho.h:825
void * myBoxPlace
Definition: Macho.h:826

Member Function Documentation

template<class S>
virtual _StateInstance* inet::Macho::_SubstateInstance< S >::create ( _MachineBase machine,
_StateInstance parent 
)
inlineoverridevirtual

Implements inet::Macho::_StateInstance.

907  {
908  return new _SubstateInstance<S>(machine, parent);
909  }
_MachineBase & machine()
Definition: Macho.h:804
template<class S>
virtual void inet::Macho::_SubstateInstance< S >::createBox ( )
inlineoverridevirtual

Implements inet::Macho::_StateInstance.

912  {
913  if (!this->myBox)
914  this->myBox = Macho::_createBox<Box>(myBoxPlace);
915  }
void * myBox
Definition: Macho.h:825
void * myBoxPlace
Definition: Macho.h:826
template<class S>
virtual void inet::Macho::_SubstateInstance< S >::deleteBox ( )
inlineoverridevirtual

Implements inet::Macho::_StateInstance.

918  {
919  assert(myBox);
920  Macho::_deleteBox<Box>(myBox, myBoxPlace);
921  }
void * myBox
Definition: Macho.h:825
void * myBoxPlace
Definition: Macho.h:826
template<class S>
virtual ID inet::Macho::_SubstateInstance< S >::id ( )
inlineoverridevirtual

Implements inet::Macho::_StateInstance.

896  {
897  return StateID<S>::value;
898  }
static const ID value
Definition: Macho.h:699
template<class S>
virtual Key inet::Macho::_SubstateInstance< S >::key ( )
inlineoverridevirtual

Implements inet::Macho::_StateInstance.

901  {
902  return S::key();
903  }
template<class S>
virtual const char* inet::Macho::_SubstateInstance< S >::name ( )
inlineoverridevirtual

Implements inet::Macho::_StateInstance.

893 { return S::_state_name(); }

Friends And Related Function Documentation

template<class S>
template<class C , class P >
friend class MachoLink
friend

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