DiaDes
0.1
DIAgnosis of Discrete-Event System
|
#include <StateInserter.hh>
Public Types | |
using | StateId = typename Fsm::StatePropertyId |
using | IdGen = _IdGenerator |
Public Member Functions | |
StateIdGenerator (const Fsm &target, IdGen &generator, bool rename) | |
StateId | generate (StateId sourceStateId) |
Private Attributes | |
Diades::Utils::Ptr< Fsm >::ConstP | _target |
Diades::Utils::Ptr< IdGen >::P | _generator |
bool | _rename |
This class is a template class that is used to generate stateId's that are not present in a target Fsm. The generation of the StateId is done by an _IdGenerator which is typically a class deriving from the Diades::Utils::IdGenerator (like PrefixedCounterIdGenerator, IncrementGenerator, ...)
A StateIdGenerator has two functioning mode. The first one is the 'rename' mode. It generates a new StateId after each call of generate that is independent from the given source state Id. If 'rename' mode is set to false, then the generator might return the given source state Id unless it was already in use in the target Fsm.
Definition at line 39 of file StateInserter.hh.
using Diades::Automata::Experimental::StateIdGenerator< Fsm, _IdGenerator >::IdGen = _IdGenerator |
Definition at line 50 of file StateInserter.hh.
using Diades::Automata::Experimental::StateIdGenerator< Fsm, _IdGenerator >::StateId = typename Fsm::StatePropertyId |
Definition at line 45 of file StateInserter.hh.
|
inline |
target | the Target Fsm |
generator | the generator that will be used to generate State Id's |
rename | the functioning mode. If rename is set to true, the generated StateId's are simply generated independently from the given source Id. If rename is set to false and the sourceId given to 'generate' is not already in the target Fsm then this id is returned as a new id for the target Fsm. |
Definition at line 83 of file StateInserter.hh.
|
inline |
sourceStateId | a stateid coming from another Fsm |
the new StateId' to include in the target Fsm
Definition at line 99 of file StateInserter.hh.
|
private |
Definition at line 61 of file StateInserter.hh.
|
private |
The functioning mode, if rename is set to true, the generated StateId's are simply generated independently from the given source Id. If rename is set to false and the sourceId given to 'generate' is not already in the target Fsm then this id is returned as a new id for the target Fsm.
Definition at line 70 of file StateInserter.hh.
|
private |
Definition at line 56 of file StateInserter.hh.