Xml::RAttribute Class Reference

class Xml::RAttribute

The RAttribute class holds an attribute's description belonging to an element. RAttributeArray

Public Member Functions
RAttribute()
IMPORT_C const RTagInfo &Attribute()
IMPORT_C voidClose()
IMPORT_C RAttributeCopy()
IMPORT_C voidOpen(const RString &, const RString &, const RString &, const TAttributeType)
IMPORT_C voidOpen(const RString &, const RString &, const RString &, const RString &, const TAttributeType)
IMPORT_C voidSetValue(const RString &)
IMPORT_C TAttributeTypeType()
IMPORT_C const RString &Value()
Private Attributes
RTagInfo iAttribute
TAttributeType iType
RString iValue

Constructor & Destructor Documentation

RAttribute()

IMPORT_CRAttribute()

Default constructor

Member Functions Documentation

Attribute()

IMPORT_C const RTagInfo &Attribute()const

This method returns a handle to the attribute's name details.

Pre-condition
The objects members have been pre-set accordingly.

Close()

IMPORT_C voidClose()

This method cleans up the object before destruction. It releases all resources in accordance to the R Class pattern.

Post-condition
This object may be allowed to go out of scope.

Copy()

IMPORT_C RAttributeCopy()

Copy method. The original and copy must be closed seperately.

Open(const RString &, const RString &, const RString &, const TAttributeType)

IMPORT_C voidOpen(const RString &aUri,
const RString &aPrefix,
const RString &aLocalName,
const TAttributeTypeaType = EAttributeType_NONE
)

This method sets the attribute's contents, taking ownership of the RStrings.

Pre-condition
The object has just been constructed and no other values have been set.
Post-condition
The objects members have been set to the values given.

Parameters

const RString & aUriThe URI of the namespace.
const RString & aPrefixThe prefix of the qualified name.
const RString & aLocalNameThe local name of the qualified name.
const TAttributeType aType = EAttributeType_NONEThe type associated with this attribute.

Open(const RString &, const RString &, const RString &, const RString &, const TAttributeType)

IMPORT_C voidOpen(const RString &aUri,
const RString &aPrefix,
const RString &aLocalName,
const RString &aValue,
const TAttributeTypeaType = EAttributeType_NONE
)

This method sets all the attribute's contents, taking ownership of the RStrings.

Pre-condition
The object has just been constructed and no other values have been set.
Post-condition
The objects members have been set to the values given.

Parameters

const RString & aUriThe URI of the namespace.
const RString & aPrefixThe prefix of the qualified name.
const RString & aLocalNameThe local name of the qualified name.
const RString & aValueThe value associated with this attribute.
const TAttributeType aType = EAttributeType_NONEThe type associated with this attribute.

SetValue(const RString &)

IMPORT_C voidSetValue(const RString &aValue)

This method sets the attribute's value, taking ownership of the RString.

Parameters

const RString & aValueThe attributes value.

Type()

IMPORT_C TAttributeTypeType()const

This method returns the attribute's type.

Pre-condition
The objects members have been pre-set accordingly.

Value()

IMPORT_C const RString &Value()const

This method returns a handle to the attribute value. If the attribute value is a list of tokens (IDREFS, ENTITIES or NMTOKENS), the tokens will be concatenated into a single RString with each token separated by a single space.

Pre-condition
The objects members have been pre-set accordingly.

Member Data Documentation

RTagInfo iAttribute

RTagInfo iAttribute[private]

Holds information about the attribute.

TAttributeType iType

TAttributeType iType[private]

Holds the attribute's type.

RString iValue

RString iValue[private]

Holds the attribute's value.