| |
libFAUDES
Sections
Index
|
faudes::TaTransSet< Attr > Class Template Reference |
Accessing individual transitions | |
typedef TTransSet < TransSort::X1EvX2 > ::Iterator | Iterator |
Iterator on transition. | |
void | Clear (void) |
Clear all transitions incl attributes. | |
bool | Insert (Idx x1, Idx ev, Idx x2) |
Add a Transition by indices. | |
bool | Insert (const Transition &rTransition) |
Add a Transition directly. | |
bool | Insert (const Transition &rTransition, const Attr &rAttr) |
Add a Transition with attribute. | |
virtual void | InsertSet (const TransSet &rOtherSet) |
Inserts transitions of rOtherSet. | |
virtual void | InsertSet (const TaTransSet &rOtherSet) |
Inserts transitions of rOtherSet. | |
bool | Erase (const Transition &t) |
Remove a Transition. | |
bool | Erase (Idx x1, Idx ev, Idx x2) |
Remove a Transition. | |
Iterator | Erase (const Iterator &it) |
Remove a Transition by iterator. | |
void | EraseByX1 (Idx x1) |
Remove all transitions containing predecessor state x1. | |
void | EraseByX2 (Idx x2) |
Remove all transitions containing successor state x2. | |
void | EraseByEv (Idx ev) |
Remove all transitions containing event ev. | |
void | EraseByX1OrX2 (Idx x) |
Remove all transitions containing state x. | |
void | EraseByX1OrX2 (const StateSet &rStateSet) |
Remove all transitions containing a specified state. | |
void | EraseSet (const TransSet &rOtherSet) |
Erase elements given by other set. | |
void | RestrictSet (const TransSet &rOtherSet) |
Restrict to specified subset. | |
virtual void | Attributes (const TransSet &rOtherSet) |
Set attributes. | |
virtual void | Attributes (const TaTransSet &rOtherSet) |
Set attributes. | |
Public Member Functions | |
virtual TaTransSet * | New (void) const |
Faudes Type interface. | |
virtual TaTransSet * | Copy (void) const |
Faudes Type interface. | |
virtual const TaTransSet * | Cast (const Type *pOther) const |
Faudes Type interface. | |
virtual TaTransSet & | Assign (const Type &rSrc) |
Assign configuration data from other object. | |
virtual bool | Equal (const Type &rOther) const |
Test equality of configuration data. | |
virtual TaTransSet & | operator= (const TaTransSet &rSrc) |
virtual bool | operator== (const TaTransSet &rOther) const |
virtual bool | operator!= (const TaTransSet &rOther) const |
Constructors & Destructor | |
We implement "protected privacy for template classes" by friendship.
This is used for the pragmatic implemention conversion constructors. | |
TaTransSet (void) | |
Construct an empty TaTransSet object. | |
TaTransSet (const TaTransSet &rOtherSet) | |
Copy-constructor (incl attributes). | |
TaTransSet (const TTransSet< TransSort::X1EvX2 > &rOtherSet) | |
Copy-Constructor (set attributes to default). | |
virtual | ~TaTransSet () |
Virtual destructor. | |
virtual TaTransSet & | Assign (const TransSet &rSrc) |
Relaxed assignment method. | |
virtual TaTransSet & | operator= (const TransSet &rSrc) |
Relaxed assignment operator. | |
Protected Member Functions | |
virtual TaTransSet & | DoAssign (const TaTransSet &rSource) |
Assign my members. |
typedef TTransSet<TransSort::X1EvX2>::Iterator faudes::TaTransSet< Attr >::Iterator |
Iterator on transition.
Reimplemented from faudes::TaBaseSet< T, Attr, Cmp >.
Definition at line 902 of file transset.h.
faudes::TaTransSet< Attr >::TaTransSet | ( | void | ) | [inline] |
faudes::TaTransSet< Attr >::TaTransSet | ( | const TaTransSet< Attr > & | rOtherSet | ) | [inline] |
faudes::TaTransSet< Attr >::TaTransSet | ( | const TTransSet< TransSort::X1EvX2 > & | rOtherSet | ) | [inline] |
virtual faudes::TaTransSet< Attr >::~TaTransSet | ( | ) | [inline, virtual] |
TaTransSet< Attr > * faudes::TaTransSet< Attr >::New | ( | void | ) | const [inline, virtual] |
Faudes Type interface.
Construct object of same type on heap.
Reimplemented from faudes::TaBaseSet< T, Attr, Cmp >.
Definition at line 1557 of file transset.h.
TaTransSet< Attr > * faudes::TaTransSet< Attr >::Copy | ( | void | ) | const [inline, virtual] |
Faudes Type interface.
Construct copy on heap.
Reimplemented from faudes::TaBaseSet< T, Attr, Cmp >.
Definition at line 1557 of file transset.h.
const TaTransSet< Attr > * faudes::TaTransSet< Attr >::Cast | ( | const Type * | pType | ) | const [inline, virtual] |
Faudes Type interface.
Cast object to my type.
Reimplemented from faudes::TaBaseSet< T, Attr, Cmp >.
Definition at line 1557 of file transset.h.
TaTransSet< Attr > & faudes::TaTransSet< Attr >::Assign | ( | const Type & | rSrc | ) | [inline, virtual] |
Assign configuration data from other object.
Derived classes should reimplement this method to first try to cast the source to the respective class. If successful, the protected function DoAssign is invoked to perform the actual assignment. If the cast fails, the Assign method of the parent class is called. Thus, faudes objects are up- and downcatsted for assignment, maintaining as much of the source data as digestable by the destination object. On the downside, there is no sensible typechecking at compile-time.
Re-implementation can be done via the convenience macros FAUDES_TYPE_DECLARATION and FAUDES_TYPE_IMPLEMENTATION.
rSrc | Source to copy from |
Reimplemented from faudes::TTransSet< Cmp >.
Definition at line 1557 of file transset.h.
bool faudes::TaTransSet< Attr >::Equal | ( | const Type & | rOther | ) | const [inline, virtual] |
Test equality of configuration data.
Derived classes should reimplement this method to return true if both actual types and configuration data match. The object name is not consired in the test.
This method calls the virtual method DoEqual(). Re-implementation can be done via the convenience macros FAUDES_TYPE_DECLARATION and FAUDES_TYPE_IMPLEMENTATION.
rOther | Other objevt to compare with. |
Reimplemented from faudes::TTransSet< Cmp >.
Definition at line 1557 of file transset.h.
TaTransSet< Attr > & faudes::TaTransSet< Attr >::operator= | ( | const TaTransSet< Attr > & | rSrc | ) | [inline, virtual] |
Definition at line 1557 of file transset.h.
bool faudes::TaTransSet< Attr >::operator== | ( | const TaTransSet< Attr > & | rOther | ) | const [inline, virtual] |
Definition at line 1557 of file transset.h.
bool faudes::TaTransSet< Attr >::operator!= | ( | const TaTransSet< Attr > & | rOther | ) | const [inline, virtual] |
Definition at line 1557 of file transset.h.
TaTransSet< Attr > & faudes::TaTransSet< Attr >::Assign | ( | const TransSet & | rSrc | ) | [inline, virtual] |
Relaxed assignment method.
Maintains attributes provided they can be casted.
rSrc | Source from which to assign |
Definition at line 1599 of file transset.h.
TaTransSet< Attr > & faudes::TaTransSet< Attr >::operator= | ( | const TransSet & | rSrc | ) | [inline, virtual] |
Relaxed assignment operator.
Maintains attributes provided they can be casted.
rSrc | Source from which to assign |
Definition at line 1610 of file transset.h.
void faudes::TaTransSet< Attr >::Clear | ( | void | ) | [inline, virtual] |
Clear all transitions incl attributes.
doxygen group
Reimplemented from faudes::TaBaseSet< T, Attr, Cmp >.
Definition at line 1615 of file transset.h.
bool faudes::TaTransSet< Attr >::Insert | ( | Idx | x1, | |
Idx | ev, | |||
Idx | x2 | |||
) | [inline] |
Add a Transition by indices.
x1 | Predecessor state | |
ev | Event | |
x2 | Successor state |
Reimplemented from faudes::TTransSet< Cmp >.
Definition at line 1627 of file transset.h.
bool faudes::TaTransSet< Attr >::Insert | ( | const Transition & | rTransition | ) | [inline] |
Add a Transition directly.
If the transition already exists, the attribute is maintained. Otherwise, the transition is inserted with default attribute.
rTransition | Reference to transition object |
Reimplemented from faudes::TTransSet< Cmp >.
Definition at line 1621 of file transset.h.
bool faudes::TaTransSet< Attr >::Insert | ( | const Transition & | rTransition, | |
const Attr & | rAttr | |||
) | [inline] |
Add a Transition with attribute.
rTransition | Reference to transition object | |
rAttr | Reference to attribute |
Definition at line 1634 of file transset.h.
void faudes::TaTransSet< Attr >::InsertSet | ( | const TransSet & | rOtherSet | ) | [inline, virtual] |
Inserts transitions of rOtherSet.
Attributes of this set are maintained, newly inserted transitions have default attribute.
rOtherSet | Other IndexSet |
Definition at line 1645 of file transset.h.
void faudes::TaTransSet< Attr >::InsertSet | ( | const TaTransSet< Attr > & | rOtherSet | ) | [inline, virtual] |
Inserts transitions of rOtherSet.
Attributes of this set are maintained, new transitions are inserted with attribute.
rOtherSet | Other IndexSet |
Definition at line 1639 of file transset.h.
bool faudes::TaTransSet< Attr >::Erase | ( | const Transition & | t | ) | [inline] |
Remove a Transition.
Reimplemented from faudes::TTransSet< Cmp >.
Definition at line 1652 of file transset.h.
bool faudes::TaTransSet< Attr >::Erase | ( | Idx | x1, | |
Idx | ev, | |||
Idx | x2 | |||
) | [inline] |
Remove a Transition.
Reimplemented from faudes::TTransSet< Cmp >.
Definition at line 1657 of file transset.h.
TaTransSet< Attr >::Iterator faudes::TaTransSet< Attr >::Erase | ( | const Iterator & | it | ) | [inline, virtual] |
Remove a Transition by iterator.
Reimplemented from faudes::TaBaseSet< T, Attr, Cmp >.
Definition at line 1664 of file transset.h.
void faudes::TaTransSet< Attr >::EraseByX1 | ( | Idx | x1 | ) | [inline] |
Remove all transitions containing predecessor state x1.
x1 | State index |
Reimplemented from faudes::TTransSet< Cmp >.
Definition at line 1676 of file transset.h.
void faudes::TaTransSet< Attr >::EraseByX2 | ( | Idx | x2 | ) | [inline] |
Remove all transitions containing successor state x2.
x2 | State index |
Reimplemented from faudes::TTransSet< Cmp >.
Definition at line 1691 of file transset.h.
void faudes::TaTransSet< Attr >::EraseByEv | ( | Idx | ev | ) | [inline] |
Remove all transitions containing event ev.
ev | Event index |
Reimplemented from faudes::TTransSet< Cmp >.
Definition at line 1708 of file transset.h.
void faudes::TaTransSet< Attr >::EraseByX1OrX2 | ( | Idx | x | ) | [inline] |
Remove all transitions containing state x.
x | State index |
Reimplemented from faudes::TTransSet< Cmp >.
Definition at line 1726 of file transset.h.
void faudes::TaTransSet< Attr >::EraseByX1OrX2 | ( | const StateSet & | rStateSet | ) | [inline] |
Remove all transitions containing a specified state.
This function iterates over all transitions to work with any sorting.
rStateSet | Set of states to remore |
Reimplemented from faudes::TTransSet< Cmp >.
Definition at line 1744 of file transset.h.
void faudes::TaTransSet< Attr >::EraseSet | ( | const TransSet & | rOtherSet | ) |
Erase elements given by other set.
This function ignores the attributes of the other set and maintains the attributes of the remaining elements in this set.
rOtherSet | Elements to erase |
void faudes::TaTransSet< Attr >::RestrictSet | ( | const TransSet & | rOtherSet | ) |
Restrict to specified subset.
Erases any elements no in the specified set. This function ignores the attributes of the other set and maintains the attributes of the remaining elements in this set.
rOtherSet | Elements to erase |
void faudes::TaTransSet< Attr >::Attributes | ( | const TransSet & | rOtherSet | ) | [inline, virtual] |
Set attributes.
Provided that rOtherSet has attributes that can be casted to the appropriate type, attributes are copied per element from rOtherSet. Elements of this set which are not in rOtherSet maintain their attribute.
rOtherSet | Other IndexSet |
Exception |
|
Definition at line 1768 of file transset.h.
void faudes::TaTransSet< Attr >::Attributes | ( | const TaTransSet< Attr > & | rOtherSet | ) | [inline, virtual] |
Set attributes.
Attributes are copied per element from rOtherSet. Elements of this set which are not in rOtherSet maintain their attribute.
rOtherSet | Other IndexSet |
Definition at line 1762 of file transset.h.
TaTransSet< Attr > & faudes::TaTransSet< Attr >::DoAssign | ( | const TaTransSet< Attr > & | rSource | ) | [inline, protected, virtual] |
Assign my members.
Maintain attributes.
rSource | Source to copy from |
Definition at line 1591 of file transset.h.
libFAUDES 2.14g --- 2009-12-3 --- c++ source docu by doxygen 1.5.6