Table of Contents

Class XMLNode

Namespace
PDFjet.NET
Assembly
PDFjet.dll

An element of an XML document that XMLParser read: its name, its attributes, its text and the elements in it.

The elements are found by a path of the names without their prefix, such as "SupplyChainTradeTransaction/ApplicableHeaderTradeAgreement/BuyerReference", because the prefixes of an invoice are its own: what one writes as ram:ID another writes as a:ID. A * matches an element of any name.

public sealed class XMLNode
Inheritance
XMLNode
Inherited Members

Methods

Find(string)

Returns the first element at the path under this one, or null.

public XMLNode Find(string path)

Parameters

path string

the path.

Returns

XMLNode

the element, or null.

FindAll(string)

Returns the elements at the path under this one, none when there are none: the names of the path are the names without their prefix, and a * matches an element of any name.

public List<XMLNode> FindAll(string path)

Parameters

path string

the path, such as "IncludedSupplyChainTradeLineItem/SpecifiedTradeProduct/Name".

Returns

List<XMLNode>

the elements.

GetAttribute(string)

Returns the value of the attribute of that name, by its name with its prefix, such as unitCode or ram:unitCode, or null when it has none.

public string GetAttribute(string attributeName)

Parameters

attributeName string

the name of the attribute.

Returns

string

the value, or null.

GetAttributes()

Returns the attributes of the element, by their names as the document writes them.

public Dictionary<string, string> GetAttributes()

Returns

Dictionary<string, string>

the attributes.

GetChildren()

Returns the elements in this one, in their order.

public List<XMLNode> GetChildren()

Returns

List<XMLNode>

the elements.

GetLocalName()

Returns the name of the element without its prefix, such as ID.

public string GetLocalName()

Returns

string

the name without its prefix.

GetName()

Returns the name of the element as the document writes it, with its prefix when it has one, such as svg:path.

public string GetName()

Returns

string

the name.

GetNamespace()

Returns the namespace of the element, the URI its prefix stands for, or an empty string when it is in no namespace.

public string GetNamespace()

Returns

string

the namespace.

GetText()

Returns the text of the element, the characters in it that are not in the elements it holds, as they are written.

public string GetText()

Returns

string

the text.

GetValue(string)

Returns the text of the first element at the path under this one, without the spaces and line breaks at its ends, or null when the path has no element.

public string GetValue(string path)

Parameters

path string

the path.

Returns

string

the text, or null.