XmlDocument::getDOM

API Ref

#include <DbXml.hpp>

DOMDocument *XmlDocument::getDOM(bool withMetaData, bool adopt=false) const;


Description: XmlDocument::getDOM

The XmlDocument::getDOM method returns the document content as a Xerces Document Object Model (DOM).

Parameters

withMetaData
A boolean flag that indicates whether to return the XmlDocument's metadata attributes in the DOM. If the flag is set to true, the metadata attributes are returned with the DOM. If the flag is set to false, the DOM is returned without the metadata attributes.

adopt
A boolean flag that indicates whether the caller is adopting responsibility for the returned DOM. If the flag is set to false, the default behavior, then the XmlDocument owns the DOM and it is its responsibility to deconstruct the DOM when the XmlDocument is deconstructed. If the flag is set to true, then the caller takes ownership of the DOM and responsibility for calling DOMDocument::release() when the DOM is no longer needed.

Errors

The XmlContainer::close method may fail and throw XmlException, encapsulating one of the following non-zero errors:

DOM_PARSER_ERROR
The document could not be returned as a DOM.

Class

XmlContainer, XmlDocument, XmlException, XmlIndexSpecification, XmlQueryContext, XmlQueryExpression, XmlResults, XmlUpdateContext, XmlValue

APIRef

Copyright (c) 1996-2003 Sleepycat Software, Inc. - All rights reserved.