ParamElement Class Reference
[Data classes]

GENERATED CLASS. More...

#include <nedelements.h>

Inheritance diagram for ParamElement:
NEDElement

List of all members.

Public Member Functions

Constructors, destructor

 ParamElement ()
 ParamElement (NEDElement *parent)
virtual ~ParamElement ()
Redefined NEDElement methods, incl. generic access to attributes

virtual const char * getTagName () const
virtual int getTagCode () const
virtual int getNumAttributes () const
virtual const char * getAttributeName (int k) const
virtual const char * getAttribute (int k) const
virtual const char * getAttribute (const char *name) const
virtual void setAttribute (int k, const char *val)
virtual void setAttribute (const char *name, const char *val)
virtual const char * getAttributeDefault (int k) const
virtual ParamElementdup () const
Typed access to attributes, children and siblings

int getType () const
void setType (int val)
bool getIsVolatile () const
void setIsVolatile (bool val)
const char * getName () const
void setName (const char *val)
const char * getValue () const
void setValue (const char *val)
bool getIsPattern () const
void setIsPattern (bool val)
bool getIsDefault () const
void setIsDefault (bool val)
virtual ParamElementgetNextParamSibling () const
virtual CommentElementgetFirstCommentChild () const
virtual ExpressionElementgetFirstExpressionChild () const
virtual PropertyElementgetFirstPropertyChild () const

Detailed Description

GENERATED CLASS.

Represents the <param> XML element in memory. DTD declaration:

 <!ELEMENT param (comment*, expression?, property*)>
 <!ATTLIST param
      type               (double|int|string|bool|xml) #IMPLIED
      is-volatile        (true|false)  "false"
      name               CDATA     #REQUIRED
      value              CDATA     #IMPLIED
      is-pattern         (true|false)  "false"
      is-default         (true|false)  "false">
 

Constructor & Destructor Documentation

ParamElement::ParamElement (  ) 
ParamElement::ParamElement ( NEDElement parent  ) 
virtual ParamElement::~ParamElement (  )  [inline, virtual]

Member Function Documentation

virtual ParamElement* ParamElement::dup (  )  const [virtual]

Creates and returns a duplicate of the element.

Child elements are not copied.

Implements NEDElement.

virtual const char* ParamElement::getAttribute ( const char *  attr  )  const [inline, virtual]

Returns the value of the attribute with the given name.

Relies on lookupAttribute() and getAttribute().

It returns NULL if the given attribute is not found.

Reimplemented from NEDElement.

References NEDElement::getAttribute().

virtual const char* ParamElement::getAttribute ( int  k  )  const [virtual]

Pure virtual method, it should be redefined in subclasses to return the value of the kth attribute (i.e.

the attribute with the name getAttributeName(k)).

It should return NULL if k is out of range (i.e. negative or greater than getNumAttributes()).

Implements NEDElement.

virtual const char* ParamElement::getAttributeDefault ( int  k  )  const [virtual]

Pure virtual method, it should be redefined in subclasses to return the default value of the kth attribute, as defined in the DTD.

It should return NULL if k is out of range (i.e. negative or greater than getNumAttributes()), or if the attribute is #REQUIRED; and return "" if the attribute is #IMPLIED.

Implements NEDElement.

virtual const char* ParamElement::getAttributeName ( int  k  )  const [virtual]

Pure virtual method, it should be redefined in subclasses to return the name of the kth attribute as defined in the DTD.

It should return NULL if k is out of range (i.e. negative or greater than getNumAttributes()).

Implements NEDElement.

virtual CommentElement* ParamElement::getFirstCommentChild (  )  const [virtual]
virtual ExpressionElement* ParamElement::getFirstExpressionChild (  )  const [virtual]
virtual PropertyElement* ParamElement::getFirstPropertyChild (  )  const [virtual]
bool ParamElement::getIsDefault (  )  const [inline]
bool ParamElement::getIsPattern (  )  const [inline]
bool ParamElement::getIsVolatile (  )  const [inline]
const char* ParamElement::getName (  )  const [inline]
virtual ParamElement* ParamElement::getNextParamSibling (  )  const [virtual]
virtual int ParamElement::getNumAttributes (  )  const [virtual]

Pure virtual method, it should be redefined in subclasses to return the number of attributes defined in the DTD.

Implements NEDElement.

virtual int ParamElement::getTagCode (  )  const [inline, virtual]

Overridden in subclasses to return the numeric code (NED_xxx) of the XML element the class represents.

Implements NEDElement.

References NED_PARAM.

virtual const char* ParamElement::getTagName (  )  const [inline, virtual]

Overridden in subclasses to return the name of the XML element the class represents.

Implements NEDElement.

int ParamElement::getType (  )  const [inline]
const char* ParamElement::getValue (  )  const [inline]
virtual void ParamElement::setAttribute ( const char *  attr,
const char *  value 
) [inline, virtual]

Sets the value of the attribute with the given name.

Relies on lookupAttribute() and setAttribute().

If the given attribute is not found, the call has no effect.

Reimplemented from NEDElement.

References NEDElement::setAttribute().

virtual void ParamElement::setAttribute ( int  k,
const char *  value 
) [virtual]

Pure virtual method, it should be redefined in subclasses to set the value of the kth attribute (i.e.

the attribute with the name getAttributeName(k)).

If k is out of range (i.e. negative or greater than getNumAttributes()), the call should be ignored.

Implements NEDElement.

void ParamElement::setIsDefault ( bool  val  )  [inline]
void ParamElement::setIsPattern ( bool  val  )  [inline]
void ParamElement::setIsVolatile ( bool  val  )  [inline]
void ParamElement::setName ( const char *  val  )  [inline]
void ParamElement::setType ( int  val  ) 
void ParamElement::setValue ( const char *  val  )  [inline]

The documentation for this class was generated from the following file:
Generated on Mon Jul 14 12:57:27 2014 for OMNeT++ NEDXML by  doxygen 1.6.3