XmlValue

API Ref

#include <DbXml.hpp>

class DbXml::XmlValue { public: ... Type getType() const; std::string getTypeURI() const; std::string getTypeName() const;

bool isType(XmlValue::Type type) const bool isNumber() const; bool isString() const; bool isBoolean() const; bool isBinary() const; bool isNode() const;

double asNumber() const; std::string asString() const; bool asBoolean() const; bool asBinary() const; DOMNode *asNode() const; const XmlDocument &asDocument() const; XmlEventReader &asEventReader() const; ... };


Description: XmlValue

Methods to retrieve information and values for any XmlValue.


Description: XmlValue::isNumber()

Returns true if the XmlValue is one of the numeric types, such as DOUBLE, FLOAT, etc.


Description: XmlValue::isString()

Returns true if the XmlValue is one of type STRING.


Description: XmlValue::isBinary()

Returns true if the XmlValue is one of type BINARY.


Description: XmlValue::isBoolean()

Returns true if the XmlValue is one of type BOOLEAN.


Description: XmlValue::isNode()

Returns true if the XmlValue is one of type NODE.


Description: XmlValue::isNull()

Returns true if the XmlValue has no value (type NONE).


Description: XmlValue::getType()

Returns the type of the XmlValue from the enumeration XmlValue::Type.

Valid values for XmlValue::Type are NONE, NODE, ANY_SIMPLE_TYPE, ANY_URI, BASE_64_BINARY, BOOLEAN, DATE, DATE_TIME, DAY_TIME_DURATION, DECIMAL, DOUBLE, DURATION, FLOAT, G_DAY, G_MONTH, G_MONTH_DAY, G_YEAR, G_YEAR_MONTH, HEX_BINARY, NOTATION, QNAME, STRING, TIME, YEAR_MONTH_DURATION, UNTYPED_ATOMIC, BINARY.


Description: XmlValue::isType(XmlValue::Type type)

Indicates whether the XmlValue is of the specified type.

Valid values for XmlValue::Type are NONE, NODE, ANY_SIMPLE_TYPE, ANY_URI, BASE_64_BINARY, BOOLEAN, DATE, DATE_TIME, DAY_TIME_DURATION, DECIMAL, DOUBLE, DURATION, FLOAT, G_DAY, G_MONTH, G_MONTH_DAY, G_YEAR, G_YEAR_MONTH, HEX_BINARY, NOTATION, QNAME, STRING, TIME, YEAR_MONTH_DURATION, UNTYPED_ATOMIC, BINARY.


Description: XmlValue::getTypeURI()

Returns the URI associated with the type of the XmlValue.


Description: XmlValue::getTypeName()

Returns the string name of the type of the XmlValue.


Description: XmlValue::asNumber()

Returns the value as a DOUBLE.


Description: XmlValue::asString()

Returns the value as a STRING.


Description: XmlValue::asBinary()

Returns the value as a BINARY if it of type XmlValue::BINARY.


Description: XmlValue::asBoolean()

Returns the value as a BOOLEAN.


Description: XmlValue::asDocument()

Returns the value as an XmlDocument.


Description: XmlValue::asNode()

Returns the value as a XercesC DOMNode.


Description: XmlValue::asEventReader()

Returns the value as an XmlEventReader. Only valid for objects of type XmlValue::NODE.


APIRef

Copyright (c) 1996,2007 Oracle. All rights reserved.