A Sandcastle Documented Class Library |
HtmlNode Members |
HtmlNode Class Constructors Methods Fields Properties See Also Send Feedback |
The HtmlNode type exposes the following members.
Constructors
Name | Description | |
---|---|---|
HtmlNode |
Initializes HtmlNode, providing type, owner and where it exists in a collection
|
Methods
Name | Description | |
---|---|---|
Ancestors()()()() |
Returns a collection of all ancestor nodes of this element.
| |
Ancestors(String) |
Get Ancestors with matching name
| |
AncestorsAndSelf()()()() |
Returns a collection of all ancestor nodes of this element.
| |
AncestorsAndSelf(String) |
Gets all anscestor nodes and the current node
| |
AppendChild |
Adds the specified node to the end of the list of children of this node.
| |
AppendChildren |
Adds the specified node to the end of the list of children of this node.
| |
CanOverlapElement |
Determines if an element node can be kept overlapped.
| |
ChildAttributes |
Gets all Attributes with name
| |
Clone |
Creates a duplicate of the node
| |
CloneNode(Boolean) |
Creates a duplicate of the node.
| |
CloneNode(String) |
Creates a duplicate of the node and changes its name at the same time.
| |
CloneNode(String, Boolean) |
Creates a duplicate of the node and changes its name at the same time.
| |
CopyFrom(HtmlNode) |
Creates a duplicate of the node and the subtree under it.
| |
CopyFrom(HtmlNode, Boolean) |
Creates a duplicate of the node.
| |
CreateNavigator |
Creates a new XPathNavigator object for navigating this HTML node.
| |
CreateNode |
Creates an HTML node from a string representing literal HTML.
| |
CreateRootNavigator |
Creates an XPathNavigator using the root of this document.
| |
DescendantNodes |
Gets all Descendant nodes for this node and each of child nodes
| |
DescendantNodesAndSelf |
Returns a collection of all descendant nodes of this element, in document order
| |
Descendants()()()() |
Gets all Descendant nodes in enumerated list
| |
Descendants(String) |
Get all descendant nodes with matching name
| |
DescendantsAndSelf()()()() |
Returns a collection of all descendant nodes of this element, in document order
| |
DescendantsAndSelf(String) |
Gets all descendant nodes including this node
| |
Element |
Gets first generation child node matching name
| |
Elements |
Gets matching first generation child nodes matching name
| |
Equals | (Inherited from Object.) | |
Finalize | Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection. (Inherited from Object.) | |
GetAttributeValue(String, Boolean) |
Helper method to get the value of an attribute of this node. If the attribute is not found, the default value will be returned.
| |
GetAttributeValue(String, Int32) |
Helper method to get the value of an attribute of this node. If the attribute is not found, the default value will be returned.
| |
GetAttributeValue(String, String) |
Helper method to get the value of an attribute of this node. If the attribute is not found, the default value will be returned.
| |
GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) | |
GetType | Gets the Type of the current instance. (Inherited from Object.) | |
InsertAfter |
Inserts the specified node immediately after the specified reference node.
| |
InsertBefore |
Inserts the specified node immediately before the specified reference node.
| |
IsCDataElement |
Determines if an element node is a CDATA element node.
| |
IsClosedElement |
Determines if an element node is closed.
| |
IsEmptyElement |
Determines if an element node is defined as empty.
| |
IsOverlappedClosingElement |
Determines if a text corresponds to the closing tag of an node that can be kept overlapped.
| |
MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) | |
PrependChild |
Adds the specified node to the beginning of the list of children of this node.
| |
PrependChildren |
Adds the specified node list to the beginning of the list of children of this node.
| |
Remove |
Removes node from parent collection
| |
RemoveAll |
Removes all the children and/or attributes of the current node.
| |
RemoveAllChildren |
Removes all the children of the current node.
| |
RemoveChild(HtmlNode) |
Removes the specified child node.
| |
RemoveChild(HtmlNode, Boolean) |
Removes the specified child node.
| |
ReplaceChild |
Replaces the child node oldChild with newChild node.
| |
SelectNodes |
Selects a list of nodes matching the XPath expression.
| |
SelectSingleNode |
Selects the first XmlNode that matches the XPath expression.
| |
SetAttributeValue |
Helper method to set the value of an attribute of this node. If the attribute is not found, it will be created automatically.
| |
ToString | (Inherited from Object.) | |
WriteContentTo()()()() |
Saves all the children of the node to a string.
| |
WriteContentTo(TextWriter) |
Saves all the children of the node to the specified TextWriter.
| |
WriteTo()()()() |
Saves the current node to a string.
| |
WriteTo(TextWriter) |
Saves the current node to the specified TextWriter.
| |
WriteTo(XmlWriter) |
Saves the current node to the specified XmlWriter.
|
Fields
Name | Description | |
---|---|---|
ElementsFlags |
Gets a collection of flags that define specific behaviors for specific element nodes.
The table contains a DictionaryEntry list with the lowercase tag name as the Key, and a combination of HtmlElementFlags as the Value.
| |
HtmlNodeTypeNameComment |
Gets the name of a comment node. It is actually defined as '#comment'.
| |
HtmlNodeTypeNameDocument |
Gets the name of the document node. It is actually defined as '#document'.
| |
HtmlNodeTypeNameText |
Gets the name of a text node. It is actually defined as '#text'.
|
Properties
Name | Description | |
---|---|---|
Attributes |
Gets the collection of HTML attributes for this node. May not be null.
| |
ChildNodes |
Gets all the children of the node.
| |
Closed |
Gets a value indicating if this node has been closed or not.
| |
ClosingAttributes |
Gets the collection of HTML attributes for the closing tag. May not be null.
| |
FirstChild |
Gets the first child of the node.
| |
HasAttributes |
Gets a value indicating whether the current node has any attributes.
| |
HasChildNodes |
Gets a value indicating whether this node has any child nodes.
| |
HasClosingAttributes |
Gets a value indicating whether the current node has any attributes on the closing tag.
| |
Id |
Gets or sets the value of the 'id' HTML attribute. The document must have been parsed using the OptionUseIdAttribute set to true.
| |
InnerHtml |
Gets or Sets the HTML between the start and end tags of the object.
| |
InnerText |
Gets or Sets the text between the start and end tags of the object.
| |
LastChild |
Gets the last child of the node.
| |
Line |
Gets the line number of this node in the document.
| |
LinePosition |
Gets the column number of this node in the document.
| |
Name |
Gets or sets this node's name.
| |
NextSibling |
Gets the HTML node immediately following this element.
| |
NodeType |
Gets the type of this node.
| |
OriginalName |
The original unaltered name of the tag
| |
OuterHtml |
Gets or Sets the object and its content in HTML.
| |
OwnerDocument |
Gets the HtmlDocument to which this node belongs.
| |
ParentNode |
Gets the parent of this node (for nodes that can have parents).
| |
PreviousSibling |
Gets the node immediately preceding this node.
| |
StreamPosition |
Gets the stream position of this node in the document, relative to the start of the document.
| |
XPath |
Gets a valid XPath string that points to this node
|