XmlModify::addUpdateStep

API Ref

#include <DbXml.hpp>

void XmlModify::addUpdateStep(const XmlQueryExpression &selectionExpr, const std::string &text)


Description: XmlModify::addUpdateStep

Replaces the targeted node's content with text. If the targeted node is an element node, all of the element node's children and text nodes are replaced with text. If the targeted node is an attribute node, the attribute's value is replaced by text. The purpose of this interface is primarily to replace text content. Note that text is treated as a text node. If it contains mark-up, that mark-up is escaped to make it legal text.

Documents resulting from this modification must be well-formed XML or an exception is thrown at modification execution time, if the documents affected are written back to their respective containers.

Parameters

selectionExpr
Provides the XQuery expression used to target the node to be updated. Use XmlManager::prepare to create the XmlQueryExpression. If zero nodes are targeted by this expression, no modifications are performed when XmlModify::execute is called.
content
The content to use as the targeted node's content.

APIRef

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