XmlCDataSection class

Applies to Windows and Windows Phone

Represents a CDATA section of an XML document.

Syntax


Public NotInheritable Class XmlCDataSection
    Implements IXmlText, _
    IXmlCharacterData, _
    IXmlNode, _
    IXmlNodeSelector, _
    IXmlNodeSerializer

Attributes

[MarshalingBehavior(Agile)]
[Version(0x06020000)]

Members

The XmlCDataSection class has these types of members:

Methods

The XmlCDataSection class has these methods. With C#, Visual Basic, and C++, it also inherits methods from the Object class.

MethodDescription
AppendChild This method is not applicable to this class. The CDataSection does not have children. This method will throw an exception.
AppendData Appends the supplied string to the existing string data.
CloneNode Clones a new node.
DeleteData Deletes specified data.
GetXml Returns the XML representation of the node and all its descendants.
HasChildNodes Determines whether a node has children. The CDataSection does not have children. This method always returns false.
InsertBefore Inserts a child node to the left of the specified node, or at the end of the child node list. This method is not applicable to this class and will throw an exception.
InsertData Inserts a string at the specified offset.
Normalize Normalizes all descendant elements by combining two or more adjacent text nodes into one unified text node.
RemoveChild Removes the specified child node from the list of children and returns it. This method is not applicable to this class as the CDataSection does not have children. This method will throw an exception.
ReplaceChild Replaces the specified old child node with the supplied new child node. This method is not applicable to this class as the CDataSection does not have children. This method will throw an exception.
ReplaceData Replaces the specified number of characters with the supplied string.
SelectNodes Applies the specified pattern-matching operation to this node's context and returns the list of matching nodes as an XmlNodeList. This method is not applicable to this class and will throw an exception.
SelectNodesNS Applies the specified pattern-matching operation to this node's context and returns the list of matching nodes as an XmlNodeList. This method is not applicable to this class and will throw an exception.
SelectSingleNode Applies the specified pattern-matching operation to this node's context and returns the first matching node. This method is not applicable to this class and will throw an exception.
SelectSingleNodeNS Applies the specified pattern-matching operation to this node's context and returns the first matching node. This method is not applicable to this class and will throw an exception.
SplitText Splits this text node into two text nodes at the specified offset and inserts the new text node into the tree as a sibling that immediately follows this node.
SubstringData Retrieves a substring of the full string from the specified range.

 

Properties

The XmlCDataSection class has these properties.

PropertyAccess typeDescription

Attributes

Read-onlyGets the list of attributes of this node.

ChildNodes

Read-onlyGets a list of children in the current node. This property always returns NULL.

Data

Read/writeGets or sets the node data depending on the node type.

FirstChild

Read-onlyGets the first child node. This property always returns NULL.

InnerText

Read/writeGets the text from inside the XML.

LastChild

Read-onlyGets the last child node. This property always returns NULL because the CDataSection does not have children.

Length

Read-onlyGets the length of the data, in Unicode characters.

LocalName

Read-onlyGets the local name, which is the local part of a qualified name. This is called the local part in Namespaces in XML.

NamespaceUri

Read-onlyReturns the Uniform Resource Identifier (URI) for the namespace.

NextSibling

Read-onlyGets the next sibling of the node in the parent's child list.

NodeName

Read-onlyReturns the qualified name for attribute, document type, element, entity, or notation nodes. Returns a fixed string for all other node types.

NodeType

Read-onlyGets the XML Document Object Model (DOM) node type, which determines valid values and whether the node can have child nodes.

NodeValue

Read/writeGets or sets the text associated with the node.

OwnerDocument

Read-onlyReturns the root of the document that contains the node.

ParentNode

Read-onlyGets the parent node of the node instance.

Prefix

Read/writeGets or sets the namespace prefix.

PreviousSibling

Read-onlyGets the previous sibling of the node in the parent's child list.

 

Requirements

Minimum supported client

Windows 8 [Windows Store apps only]

Minimum supported server

Windows Server 2012 [Windows Store apps only]

Minimum supported phone

Windows Phone 8.1 [Windows Phone Silverlight 8.1 and Windows Runtime apps]

Namespace

Windows.Data.Xml.Dom
Windows::Data::Xml::Dom [C++]

Metadata

Windows.winmd

 

 

Show:
© 2014 Microsoft