GroveAttr — XML element attribute node.
class GroveAttr : : public GroveNodeWithNamespaceSernaApi::GroveNodeWithNamespace { public: enum Defaulted; // Attribute value type. enum AttrType { INVALID, IMPLIED, CDATA, TOKENIZED }; // ID class of the attribute. Note that IDREFS is not yet supported. enum IdClass { NOT_ID, IS_ID, IS_IDREF, IS_IDREFS }; // construct/copy/destruct GroveAttr(SernaApiBase *); GroveAttr(const SString &, const SString & = SString()); ~GroveAttr(); // public member functions GroveElement element() const; bool specified() const; SString value() const; void build() ; void setValue(const SString &) ; void setName(const SString &) ; bool tokenized() const; Defaulted defaulted() const; AttrType type() const; void setDefaulted(const Defaulted) ; void setType(const AttrType) ; IdClass idClass() const; void setIdClass(IdClass) ; };
GroveAttr
public member functionsGroveElement element() const;
Returns parent element.
Check whether value of this attribute was explicitly specified (not defaulted via dtd/prolog/schema)
SString value() const;
A string value of an attribute. For tokenized values, this is a concatenation of tokens with single blank as a separator.
Build string attribute value (which can be accessed via value() member function) from attribute node children.
Sets CDATA-only attribute value.
Sets the new name of an attribute. This function also performs name parsing and namespace processing, if necessary.
True if attribute is tokenized.
Returns defaulting type of attribute (see enum Defaulted).
Attribute value type.
Set attribute specification (defaulting) type.
Set attribute value type.
Returns ID class.
Set new ID class. Use with caution.