Parameter. More...

#include <rparam.h>

Inheritance diagram for RParam:
[legend]
Collaboration diagram for RParam:
[legend]

Public Member Functions

 RParam (const RString &n, const RString &desc=RString::Null)
 
RString GetName (void) const
 
RString GetDescription (void) const
 
int Compare (const RString &name) const
 
int Compare (const RParam &param) const
 
virtual void AddTag (RXMLStruct *xml, RXMLTag *parent)
 
virtual bool Set (RXMLTag *parent)
 
virtual void Reset (void)
 
virtual ~RParam (void)
 

Protected Attributes

RString Name
 
RString Description
 

Detailed Description

Parameter.

The RParam class provides a representation for a parameter.

Constructor & Destructor Documentation

RParam ( const RString n,
const RString desc = RString::Null 
)

Constructor of the parameter.

Parameters
nName of the parameter.
descDescription of the parameter.
virtual ~RParam ( void  )
virtual

Destruct.

Member Function Documentation

RString GetName ( void  ) const

Get the name of the parameter.

RString GetDescription ( void  ) const

Get the description of the parameter.

int Compare ( const RString name) const

Compare the name of the parameter with a given string. This function is used by RContainer.

Parameters
nameThe string used for the comparison.
Returns
-1,0 or 1 if the parameter is greater, the same or lesser than the parameter.
int Compare ( const RParam param) const

Compare the names of two parameters. This function is used by RContainer.

Parameters
paramThe parameter used for the comparison.
Returns
-1,0 or 1 if the parameter is greater, the same or lesser than the parameter.
virtual void AddTag ( RXMLStruct xml,
RXMLTag parent 
)
virtual

Add a tag representing the values of the parameter.

Parameters
xmlXML structure.
parentParent tag.

Reimplemented in RParamStruct, RParamList, and RParamValue.

virtual bool Set ( RXMLTag parent)
virtual

Set the parameter based on a tag.

Parameters
parentTag.
Returns
true if the tag correspond to the current parameter or false if not.

Reimplemented in RParamStruct, RParamList, and RParamValue.

virtual void Reset ( void  )
virtual

Reset the value of the parameter.

Reimplemented in RParamStruct, RParamList, and RParamValue.

Field Documentation

RString Name
protected

Name of the parameter.

RString Description
protected

Description of the parameter.