libFAUDES

Sections

Index

faudes::AttributeColoredState Class Reference
[Multitasking PlugIn]

#include <mtc_attributes.h>

Inherits faudes::AttributeFlags.

List of all members.


Detailed Description

State attributes for multitasking automata.

Definition at line 41 of file mtc_attributes.h.


Public Member Functions

virtual AttributeColoredStateNew (void) const
 Construct on heap.
virtual AttributeColoredStateCopy (void) const
 Construct on heap.
virtual const
AttributeColoredState
Cast (const Type *pOther) const
 Cast other object to this type.
virtual AttributeColoredStateAssign (const Type &rSrc)
 Assign configuration data from other object.
virtual bool Equal (const Type &rOther) const
 Test equality of configuration data.
virtual AttributeColoredStateoperator= (const AttributeColoredState &rSrc)
virtual bool operator== (const AttributeColoredState &rOther) const
virtual bool operator!= (const AttributeColoredState &rOther) const
 AttributeColoredState (void)
 Default constructor.
virtual ~AttributeColoredState (void)
bool IsDefault (void) const
 Test for default value.
NameSet::Iterator ColorsBegin () const
 Iterator for first entry in mColors.
NameSet::Iterator ColorsEnd () const
 Iterator for last entry in mColors.
const ColorSetColors (void) const
 Read access to color set.
ColorSetColors (void)
 Writable access to color set.
void Colors (const ColorSet &rColors)
 Set the color set.
void ColorSymTab (SymbolTable *pSymTab)
 Set pointer to color symbol table.
SymbolTableColorSymTabp (void) const
 Get pointer to color symbol table.

Protected Member Functions

virtual AttributeColoredStateDoAssign (const AttributeColoredState &rSrcAttr)
 Assignment method.
virtual bool DoEqual (const AttributeColoredState &rOther) const
 Test equality of configuration data.
virtual void DoWrite (TokenWriter &rTw, const std::string &rLabel="", const Type *pContext=0) const
 Write attributes to tokenwriter.
virtual void DoRead (TokenReader &rTr, const std::string &rLabel="", const Type *pContext=0)
 Read attributes from tokenreader.

Protected Attributes

ColorSet mColors
 Colorset.
SymbolTablempColorSymbolTable
 Pointer to colorsymboltable.

Constructor & Destructor Documentation

faudes::AttributeColoredState::AttributeColoredState ( void   )  [inline]

Default constructor.

Definition at line 49 of file mtc_attributes.h.

virtual faudes::AttributeColoredState::~AttributeColoredState ( void   )  [inline, virtual]

Definition at line 52 of file mtc_attributes.h.


Member Function Documentation

AttributeColoredState * faudes::AttributeColoredState::New ( void   )  const [virtual]

Construct on heap.

Technically not a constructor, this function creates an object with the same type Type. New() is defined as a virtual function and derived classes are meant to re-implement with the appropiate constructor. This can be done via the provided macros FAUDES_TYPE_DECLARATION and FAUDES_TYPE_IMPLEMENTATION. As with new, it is the callers reponsabilty to delete the object when no longer needed.

Returns:
Pointer to new Type object

Reimplemented from faudes::AttributeFlags.

Definition at line 33 of file mtc_attributes.cpp.

AttributeColoredState * faudes::AttributeColoredState::Copy ( void   )  const [virtual]

Construct on heap.

Technically not a constructor, this function creates an object with the same type Type and the same configuration. Copy() is defined as a virtual function and derived classes are meant to re-implement with the appropiate copy constructor. This can be done via the provided macros FAUDES_TYPE_DECLARATION and FAUDES_TYPE_IMPLEMENTATION. As with new, it is the callers reponsabilty to delete the object when no longer needed.

Returns:
Pointer to new Type object

Reimplemented from faudes::AttributeFlags.

Definition at line 33 of file mtc_attributes.cpp.

const AttributeColoredState * faudes::AttributeColoredState::Cast ( const Type pOther  )  const [virtual]

Cast other object to this type.

Enables the run-time interface to test whether pObject is derived from this object. This feature is used e.g. in the faudes container classes to test attributes. Derived classes must reimplement this function using the appropriate dynamic cast.

Re-implementation can be done via the convenience macros FAUDES_TYPE_DECLARATION and FAUDES_TYPE_IMPLEMENTATION.

Returns:
Typed pointer object

Reimplemented from faudes::AttributeFlags.

Definition at line 33 of file mtc_attributes.cpp.

AttributeColoredState & faudes::AttributeColoredState::Assign ( const Type rSrc  )  [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.

Parameters:
rSrc Source to copy from
Returns:
Reference to this object.

Reimplemented from faudes::AttributeFlags.

Definition at line 33 of file mtc_attributes.cpp.

bool faudes::AttributeColoredState::Equal ( const Type rOther  )  const [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.

Parameters:
rOther Other objevt to compare with.
Returns:
True on match.

Reimplemented from faudes::AttributeFlags.

Definition at line 33 of file mtc_attributes.cpp.

AttributeColoredState & faudes::AttributeColoredState::operator= ( const AttributeColoredState rSrc  )  [virtual]

Definition at line 33 of file mtc_attributes.cpp.

bool faudes::AttributeColoredState::operator== ( const AttributeColoredState rOther  )  const [virtual]

Definition at line 33 of file mtc_attributes.cpp.

bool faudes::AttributeColoredState::operator!= ( const AttributeColoredState rOther  )  const [virtual]

Definition at line 33 of file mtc_attributes.cpp.

bool faudes::AttributeColoredState::IsDefault ( void   )  const [inline, virtual]

Test for default value.

Returns:
True for defaultvalue

Reimplemented from faudes::AttributeFlags.

Definition at line 60 of file mtc_attributes.h.

NameSet::Iterator faudes::AttributeColoredState::ColorsBegin (  )  const

Iterator for first entry in mColors.

Definition at line 74 of file mtc_attributes.cpp.

NameSet::Iterator faudes::AttributeColoredState::ColorsEnd (  )  const

Iterator for last entry in mColors.

Definition at line 79 of file mtc_attributes.cpp.

const ColorSet& faudes::AttributeColoredState::Colors ( void   )  const [inline]

Read access to color set.

Returns:
Reference to attribute data

Definition at line 78 of file mtc_attributes.h.

ColorSet& faudes::AttributeColoredState::Colors ( void   )  [inline]

Writable access to color set.

Returns:
Reference to attribute data

Definition at line 87 of file mtc_attributes.h.

void faudes::AttributeColoredState::Colors ( const ColorSet rColors  )  [inline]

Set the color set.

Parameters:
rColors New color set

Definition at line 95 of file mtc_attributes.h.

void faudes::AttributeColoredState::ColorSymTab ( SymbolTable pSymTab  ) 

Set pointer to color symbol table.

Parameters:
pSymTab New color symbol table

Definition at line 84 of file mtc_attributes.cpp.

SymbolTable * faudes::AttributeColoredState::ColorSymTabp ( void   )  const

Get pointer to color symbol table.

Returns:
Pointer to current color symbol table

Definition at line 89 of file mtc_attributes.cpp.

AttributeColoredState & faudes::AttributeColoredState::DoAssign ( const AttributeColoredState rSrcAttr  )  [protected, virtual]

Assignment method.

Parameters:
rSrcAttr Source to assign from

Definition at line 36 of file mtc_attributes.cpp.

bool faudes::AttributeColoredState::DoEqual ( const AttributeColoredState rOther  )  const [protected, virtual]

Test equality of configuration data.

Parameters:
rOther Other attribute to compare with.
Returns:
True on match.

Definition at line 45 of file mtc_attributes.cpp.

void faudes::AttributeColoredState::DoWrite ( TokenWriter rTw,
const std::string &  rLabel = "",
const Type pContext = 0 
) const [protected, virtual]

Write attributes to tokenwriter.

Parameters:
rTw Tokenreader to write to
rLabel Section to write
pContext Write context to provide contextual information
Exceptions:
Exception I/O errors

Reimplemented from faudes::AttributeFlags.

Definition at line 57 of file mtc_attributes.cpp.

void faudes::AttributeColoredState::DoRead ( TokenReader rTr,
const std::string &  rLabel = "",
const Type pContext = 0 
) [protected, virtual]

Read attributes from tokenreader.

Parameters:
rTr Tokenreader to read from
rLabel Section to read
pContext Read context to provide contextual information
Exceptions:
Exception Thrown on file format errors (ids 50, 51)

Reimplemented from faudes::AttributeFlags.

Definition at line 63 of file mtc_attributes.cpp.


Member Data Documentation

Colorset.

Definition at line 116 of file mtc_attributes.h.

Pointer to colorsymboltable.

Definition at line 119 of file mtc_attributes.h.


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

libFAUDES 2.14g --- 2009-12-3 --- c++ source docu by doxygen 1.5.6