ADTF
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
cDDLComplex

Representation for a complex datatype inside a DDL specification. More...

#include <ddlcomplex.h>

Inheritance diagram for cDDLComplex:
[legend]

Public Member Functions

 cDDLComplex ()
 Default CTOR.
 
 cDDLComplex (const A_UTILS_NS::cString &strName, unsigned int const uiVersion, const A_UTILS_NS::cString &strComment=A_UTILS_NS::cString::Empty, cDDLAlignment::tAlignment const eAlignment=cDDLAlignment::e1, tDDLElementVec vecDDLElements=tDDLElementVec(), int const nCreationLevel=1, double fLanguageVersion=cDDLVersionHelper::GetDefaultVersion())
 CTOR.
 
 cDDLComplex (cDDLComplex &oStruct)
 Copy CTOR.
 
virtual ~cDDLComplex ()
 DTOR.
 
tResult Accept (IDDLVisitor *poVisitor)
 Acceptance method for Visitor design-pattern.
 
const A_UTILS_NS::cStringGetName () const
 Getter for the name of the representation object.
 
void SetName (const A_UTILS_NS::cString &strName)
 Setter for the name of the complex datatype.
 
bool IsInitialized () const
 Getter for the initialization flag.
 
bool IsPredefined () const
 Getter for the predefinition flag.
 
bool IsOverwriteable () const
 Getter for the predefinition flag.
 
int GetCreationLevel () const
 Getter for the creation level.
 
tResult Create (const A_UTILS_NS::cString &strName, unsigned int const uiVersion, const A_UTILS_NS::cString &strComment=A_UTILS_NS::cString::Empty, cDDLAlignment::tAlignment const eAlignment=cDDLAlignment::e1, tDDLElementVec vecDDLElements=tDDLElementVec(), int const nCreationLevel=1)
 Creation method to fill the object with data.
 
unsigned int GetVersion () const
 Getter for the version.
 
void SetVersion (unsigned int const uiVersion)
 Setter for the version.
 
double GetDDLVersion () const
 Getter for the DDL version.
 
tResult SetDDLVersion (double const fLanguageVersion)
 Setter for the DDL version.
 
void SetComment (const A_UTILS_NS::cString &strComment)
 Setter for the comment.
 
A_UTILS_NS::cString GetComment () const
 Getter for the comment.
 
void SetAlignment (cDDLAlignment::tAlignment const eAlignment)
 Setter for the alignment.
 
void CloneElements (tDDLElementVec vecDDLElements)
 Setter for the element vector.
 
void RefElements (tDDLElementVec vecDDLElements)
 Setter for the element vector.
 
void AddElement (cDDLElement *poElement, int nPos=-1)
 Adder for an element.
 
tResult RemoveElement (const A_UTILS_NS::cString &strElementName)
 removal for an element.
 
const tDDLElementVecGetElements () const
 Getter for the elements.
 
tDDLElementVecGetElements ()
 Getter for the elements.
 
cDDLAlignment::tAlignment GetAlignment () const
 Getter for the alignment of the complex datatype.
 
- Public Member Functions inherited from IDDLDataType
virtual ~IDDLDataType ()
 Virtual DTOR.
 
- Public Member Functions inherited from IDDL
virtual ~IDDL ()
 Virtual DTOR.
 

Private Attributes

double m_fLanguageVersion
 The DDL Version this structure was created in.
 
A_UTILS_NS::cString m_strName
 
unsigned int m_uiVersion
 
A_UTILS_NS::cString m_strComment
 
cDDLAlignment::tAlignment m_eAlignment
 
tDDLElementVec m_vecDDLElements
 
bool m_bInitFlag
 
int m_nLevel
 

Additional Inherited Members

- Public Types inherited from IDDL
enum  tag_MergeFlags { DDLMERGE_ForceOverwrite = 0x01 }
 Flags for Merging. More...
 

Detailed Description

Representation for a complex datatype inside a DDL specification.

Definition at line 34 of file ddlcomplex.h.

Constructor & Destructor Documentation

◆ cDDLComplex() [1/2]

cDDLComplex ( const A_UTILS_NS::cString & strName,
unsigned int const uiVersion,
const A_UTILS_NS::cString & strComment = A_UTILS_NS::cString::Empty,
cDDLAlignment::tAlignment const eAlignment = cDDLAlignment::e1,
tDDLElementVec vecDDLElements = tDDLElementVec(),
int const nCreationLevel = 1,
double fLanguageVersion = cDDLVersionHelper::GetDefaultVersion() )

CTOR.

Parameters
[in]strName- Name of the data type
[in]uiVersion- Version number of the specified data type
[in]strComment- Additional comments (optional)
[in]eAlignment- Alignment value (optional)
[in]vecDDLElements- Vector of sub elements (optional)
[in]nCreationLevel- Level at creation time (optional)
[in]fLanguageVersion- language version (optional)

References cDDLComplex().

◆ cDDLComplex() [2/2]

cDDLComplex ( cDDLComplex & oStruct)

Copy CTOR.

Parameters
[in]oStruct- Reference to complex datatype object to copy

References cDDLComplex().

Member Function Documentation

◆ Accept()

tResult Accept ( IDDLVisitor * poVisitor)
virtual

Acceptance method for Visitor design-pattern.

Parameters
[in]poVisitor- Pointer to Visitor instance
Return values
ERR_POINTERNull-pointer committed
ERR_NOT_FOUNDRequired node not found.
ERR_NOT_INITIALIZEDThe object was not or not correctly initialized

Implements IDDL.

References Accept().

Referenced by Accept().

◆ AddElement()

void AddElement ( cDDLElement * poElement,
int nPos = -1 )

Adder for an element.

Parameters
[in]poElement- Pointer to the element to add
[in]nPos- Position to add the element
Returns
void

References AddElement().

Referenced by AddElement().

◆ CloneElements()

void CloneElements ( tDDLElementVec vecDDLElements)

Setter for the element vector.

Parameters
[in]vecDDLElements- Vector of elements
Returns
void

References CloneElements().

Referenced by CloneElements().

◆ Create()

tResult Create ( const A_UTILS_NS::cString & strName,
unsigned int const uiVersion,
const A_UTILS_NS::cString & strComment = A_UTILS_NS::cString::Empty,
cDDLAlignment::tAlignment const eAlignment = cDDLAlignment::e1,
tDDLElementVec vecDDLElements = tDDLElementVec(),
int const nCreationLevel = 1 )

Creation method to fill the object with data.

Parameters
[in]strName- Name of the data type
[in]uiVersion- Version number of the specified data type
[in]strComment- Additional comments (optional)
[in]eAlignment- Alignment value (optional)
[in]vecDDLElements- Vector of sub elements (optional)
[in]nCreationLevel- Level at creation time (optional)
Return values
ERR_INVALID_ARGEmpty name committed

References Create().

Referenced by Create().

◆ GetAlignment()

cDDLAlignment::tAlignment GetAlignment ( ) const

Getter for the alignment of the complex datatype.

Returns
the alignment

References GetAlignment().

Referenced by GetAlignment().

◆ GetComment()

A_UTILS_NS::cString GetComment ( ) const

Getter for the comment.

Returns
the comment

References GetComment().

Referenced by GetComment().

◆ GetCreationLevel()

int GetCreationLevel ( ) const
virtual

Getter for the creation level.

Returns
the level at creation time of this representation object

Implements IDDL.

References GetCreationLevel().

Referenced by GetCreationLevel().

◆ GetDDLVersion()

double GetDDLVersion ( ) const

Getter for the DDL version.

Returns
the DDL version

References GetDDLVersion().

Referenced by GetDDLVersion().

◆ GetElements() [1/2]

tDDLElementVec & GetElements ( )

Getter for the elements.

Returns
vector of the elements

References GetElements().

◆ GetElements() [2/2]

const tDDLElementVec & GetElements ( ) const

Getter for the elements.

Returns
vector of the elements

References GetElements().

Referenced by GetElements(), and GetElements().

◆ GetName()

const A_UTILS_NS::cString & GetName ( ) const
virtual

Getter for the name of the representation object.

Returns
the name

Implements IDDL.

References GetName().

Referenced by GetName().

◆ GetVersion()

unsigned int GetVersion ( ) const

Getter for the version.

Returns
the version

References GetVersion().

Referenced by GetVersion().

◆ IsInitialized()

bool IsInitialized ( ) const
virtual

Getter for the initialization flag.

Return values
trueThe object was initialized correctly
falseThe object was not or not correctly initialized

Implements IDDL.

References IsInitialized().

Referenced by IsInitialized().

◆ IsOverwriteable()

bool IsOverwriteable ( ) const
virtual

Getter for the predefinition flag.

Return values
trueThe object was predefined
falseThe object was defined later

Implements IDDL.

References IsOverwriteable().

Referenced by IsOverwriteable().

◆ IsPredefined()

bool IsPredefined ( ) const
virtual

Getter for the predefinition flag.

Return values
trueThe object was predefined
falseThe object was defined later

Implements IDDL.

References IsPredefined().

Referenced by IsPredefined().

◆ RefElements()

void RefElements ( tDDLElementVec vecDDLElements)

Setter for the element vector.

Parameters
[in]vecDDLElements- Vector of elements
Returns
void

References RefElements().

Referenced by RefElements().

◆ RemoveElement()

tResult RemoveElement ( const A_UTILS_NS::cString & strElementName)

removal for an element.

Parameters
[in]strElementName- name of the element to remove
Return values
ERR_NOT_FOUNDif not found

References RemoveElement().

Referenced by RemoveElement().

◆ SetAlignment()

void SetAlignment ( cDDLAlignment::tAlignment const eAlignment)

Setter for the alignment.

Parameters
[in]eAlignment- Alignment value
Returns
void

References SetAlignment().

Referenced by SetAlignment().

◆ SetComment()

void SetComment ( const A_UTILS_NS::cString & strComment)

Setter for the comment.

Parameters
[in]strComment- Additional comments
Returns
void

References SetComment().

Referenced by SetComment().

◆ SetDDLVersion()

tResult SetDDLVersion ( double const fLanguageVersion)

Setter for the DDL version.

Parameters
fLanguageVersionthe DDL version to set
Returns
Standard result code.
Return values
ERR_NOERROR

References SetDDLVersion().

Referenced by SetDDLVersion().

◆ SetName()

void SetName ( const A_UTILS_NS::cString & strName)

Setter for the name of the complex datatype.

Parameters
[in]strName- Name of the complex datatype
Returns
void

References SetName().

Referenced by SetName().

◆ SetVersion()

void SetVersion ( unsigned int const uiVersion)

Setter for the version.

Parameters
uiVersionthe version to set
Returns
void

References SetVersion().

Referenced by SetVersion().

Member Data Documentation

◆ m_bInitFlag

bool m_bInitFlag
private

Definition at line 219 of file ddlcomplex.h.

◆ m_eAlignment

cDDLAlignment::tAlignment m_eAlignment
private

Definition at line 216 of file ddlcomplex.h.

◆ m_fLanguageVersion

double m_fLanguageVersion
private

The DDL Version this structure was created in.

Definition at line 212 of file ddlcomplex.h.

◆ m_nLevel

int m_nLevel
private

Definition at line 220 of file ddlcomplex.h.

◆ m_strComment

A_UTILS_NS::cString m_strComment
private

Definition at line 215 of file ddlcomplex.h.

◆ m_strName

A_UTILS_NS::cString m_strName
private

Definition at line 213 of file ddlcomplex.h.

◆ m_uiVersion

unsigned int m_uiVersion
private

Definition at line 214 of file ddlcomplex.h.

◆ m_vecDDLElements

tDDLElementVec m_vecDDLElements
private

Definition at line 217 of file ddlcomplex.h.