DiaDes  0.1
DIAgnosis of Discrete-Event System
Public Types | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | List of all members
Diades::Sdmdl::BddComponent Class Reference

#include <BddComponent.hh>

Public Types

typedef Diades::Utils::Exception< BddComponentException
 
typedef Variable::VariableVector VariableVector
 
typedef Formula::FormulaVector FormulaVector
 
typedef Formula SlStates
 
typedef Formula SlTransitions
 
typedef Formula SlEvents
 

Public Member Functions

 BddComponent ()
 
 ~BddComponent ()
 
void encodeComponent (FormulaFactory &factory, const SynchronisationRules &model, const Component &component, Variable &stateVar, Variable &nextStateVar, Variable &event)
 
void encodeComponent (FormulaFactory &factory, const Component &component, Variable &stateVar, Variable &nextStateVar, Variable &event)
 
const SlStatesinitialStates () const
 
const SlTransitionstransitions () const
 
const SlTransitionstransitions (const SlEvents &evt) const
 
const SlTransitionsnoTransitions () const
 
const SlTransitionstransitions (const SlStates &sources, const SlEvents &events) const
 
const SlEventsevents (std::set< Event > &events)
 
const SlEventsevent (const Event &event)
 
const SlStatestrigger (const SlStates &sources, const SlEvents &events) const
 
const SlStatessynchronousTrigger (const SlStates &sources, const SlEvents &events) const
 
const SlStatesreach (const SlStates &sources, const SlEvents &nonObservables, const SlEvents &observations)
 

Static Public Member Functions

static string typeName ()
 

Private Member Functions

FormulaFactoryfactory ()
 
void clear ()
 
void encodeEventLabels (const SynchronisationRules &model, const Component &component)
 
void encodeEventLabels (const Component &component)
 
void encodeInitialStates (const Component &component)
 
void encodeTransitions (const Component &component)
 
const FormulaencodeTransition (const Component &component, const Transition &transition)
 

Private Attributes

FormulaVector _behaviour
 
FormulaVector _initialState
 
FormulaVector _noTransitions
 
unordered_map< string, size_t > _eventLabels
 
FormulaVector _events
 
FormulaVector _setOfEvents
 
VariableVector _stateVariable
 
VariableVector _nextStateVariable
 
VariableVector _eventVariable
 
vector< reference_wrapper< FormulaFactory > > _factory
 

Detailed Description

This class implements a automaton component with help of Bdds (Formula)

Definition at line 35 of file BddComponent.hh.

Member Typedef Documentation

◆ Exception

Definition at line 39 of file BddComponent.hh.

◆ FormulaVector

Definition at line 41 of file BddComponent.hh.

◆ SlEvents

Definition at line 44 of file BddComponent.hh.

◆ SlStates

Definition at line 42 of file BddComponent.hh.

◆ SlTransitions

Definition at line 43 of file BddComponent.hh.

◆ VariableVector

Definition at line 40 of file BddComponent.hh.

Constructor & Destructor Documentation

◆ BddComponent()

Diades::Sdmdl::BddComponent::BddComponent ( )
inline

Constructor

Definition at line 65 of file BddComponent.hh.

◆ ~BddComponent()

Diades::Sdmdl::BddComponent::~BddComponent ( )
inline

Destructor

Definition at line 75 of file BddComponent.hh.

References encodeComponent(), event(), and factory().

Member Function Documentation

◆ clear()

void Diades::Sdmdl::BddComponent::clear ( )
private

Clear the component

Referenced by factory().

◆ encodeComponent() [1/2]

void Diades::Sdmdl::BddComponent::encodeComponent ( FormulaFactory factory,
const SynchronisationRules model,
const Component component,
Variable stateVar,
Variable nextStateVar,
Variable event 
)

Encode a component (part of a system through a SynchronisationRules's model)

Parameters
factorythe formula factory
modelthe component-based model
componentthe component to encode
stateVarthe state variable associated to the component to encode
nextStateVarthe next-state variable associated to the component to encode
eventthe event variable

Referenced by ~BddComponent().

◆ encodeComponent() [2/2]

void Diades::Sdmdl::BddComponent::encodeComponent ( FormulaFactory factory,
const Component component,
Variable stateVar,
Variable nextStateVar,
Variable event 
)

Encode a component (standalone)

Parameters
factorythe formula factory
componentthe component to encode
stateVarthe state variable associated to the component to encode
nextStateVarthe next-state variable associated to the component to encode
eventthe event variable

◆ encodeEventLabels() [1/2]

void Diades::Sdmdl::BddComponent::encodeEventLabels ( const SynchronisationRules model,
const Component component 
)
private
Parameters
componentthe component to encode

Referenced by factory().

◆ encodeEventLabels() [2/2]

void Diades::Sdmdl::BddComponent::encodeEventLabels ( const Component component)
private
Parameters
componentthe component to encode

◆ encodeInitialStates()

void Diades::Sdmdl::BddComponent::encodeInitialStates ( const Component component)
private
Parameters
componentthe component to encode

Referenced by factory().

◆ encodeTransition()

const Formula& Diades::Sdmdl::BddComponent::encodeTransition ( const Component component,
const Transition transition 
)
private
Parameters
componentthe component to encode

Referenced by factory().

◆ encodeTransitions()

void Diades::Sdmdl::BddComponent::encodeTransitions ( const Component component)
private
Parameters
componentthe component to encode

Referenced by factory().

◆ event()

const SlEvents& Diades::Sdmdl::BddComponent::event ( const Event event)
Returns
the formula corresponding to the event

Referenced by transitions(), and ~BddComponent().

◆ events()

const SlEvents& Diades::Sdmdl::BddComponent::events ( std::set< Event > &  events)
Returns
the formula corresponding to the set of events

Referenced by transitions().

◆ factory()

FormulaFactory& Diades::Sdmdl::BddComponent::factory ( )
inlineprivate

◆ initialStates()

const SlStates& Diades::Sdmdl::BddComponent::initialStates ( ) const
inline
Returns
the set of initial states

Definition at line 120 of file BddComponent.hh.

References require.

◆ noTransitions()

const SlTransitions& Diades::Sdmdl::BddComponent::noTransitions ( ) const
Returns
the no-effective transition move formula

Referenced by transitions().

◆ reach()

const SlStates& Diades::Sdmdl::BddComponent::reach ( const SlStates sources,
const SlEvents nonObservables,
const SlEvents observations 
)
Parameters
sources
nonObservables
observations
Returns
the set of target states that can be reached after observing one of the observations after sequence of nonObservable events from the set sources.

Referenced by transitions().

◆ synchronousTrigger()

const SlStates& Diades::Sdmdl::BddComponent::synchronousTrigger ( const SlStates sources,
const SlEvents events 
) const

Trigger one event belonging to the set of events from the set of sources

Parameters
sources
events
Returns
the set of target states such that there exists at least one source state and one event in a component transition that leads to the target state. If the events do not belong to the components return the current states.

Referenced by transitions().

◆ transitions() [1/3]

const SlTransitions& Diades::Sdmdl::BddComponent::transitions ( ) const
inline

Definition at line 128 of file BddComponent.hh.

References require.

◆ transitions() [2/3]

const SlTransitions& Diades::Sdmdl::BddComponent::transitions ( const SlEvents evt) const
inline

Definition at line 135 of file BddComponent.hh.

References noTransitions(), and require.

◆ transitions() [3/3]

const SlTransitions& Diades::Sdmdl::BddComponent::transitions ( const SlStates sources,
const SlEvents events 
) const
inline

Definition at line 151 of file BddComponent.hh.

References event(), events(), reach(), require, synchronousTrigger(), and trigger().

◆ trigger()

const SlStates& Diades::Sdmdl::BddComponent::trigger ( const SlStates sources,
const SlEvents events 
) const

Trigger one event belonging to the set of events from the set of sources

Parameters
sources
events
Returns
the set of target states such that there exists at least one source state and one event in a component transition that leads to the target state

Referenced by transitions().

◆ typeName()

static string Diades::Sdmdl::BddComponent::typeName ( )
inlinestatic

Definition at line 38 of file BddComponent.hh.

Member Data Documentation

◆ _behaviour

FormulaVector Diades::Sdmdl::BddComponent::_behaviour
private

Definition at line 48 of file BddComponent.hh.

◆ _eventLabels

unordered_map<string,size_t> Diades::Sdmdl::BddComponent::_eventLabels
private

Definition at line 51 of file BddComponent.hh.

◆ _events

FormulaVector Diades::Sdmdl::BddComponent::_events
private

Definition at line 52 of file BddComponent.hh.

◆ _eventVariable

VariableVector Diades::Sdmdl::BddComponent::_eventVariable
private

Definition at line 56 of file BddComponent.hh.

◆ _factory

vector< reference_wrapper<FormulaFactory> > Diades::Sdmdl::BddComponent::_factory
mutableprivate

Definition at line 58 of file BddComponent.hh.

◆ _initialState

FormulaVector Diades::Sdmdl::BddComponent::_initialState
private

Definition at line 49 of file BddComponent.hh.

◆ _nextStateVariable

VariableVector Diades::Sdmdl::BddComponent::_nextStateVariable
private

Definition at line 55 of file BddComponent.hh.

◆ _noTransitions

FormulaVector Diades::Sdmdl::BddComponent::_noTransitions
mutableprivate

Definition at line 50 of file BddComponent.hh.

◆ _setOfEvents

FormulaVector Diades::Sdmdl::BddComponent::_setOfEvents
private

Definition at line 53 of file BddComponent.hh.

◆ _stateVariable

VariableVector Diades::Sdmdl::BddComponent::_stateVariable
private

Definition at line 54 of file BddComponent.hh.


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