Class Attr

Class Attr

Namespace: Aspose.Html.Dom
Assembly: Aspose.HTML.dll (25.2.0)

The Attr interface represents an attribute in an Element object. Typically the allowable values for the attribute are defined in a schema associated with the document.

[DOMName("Attr")]
[ComVisible(true)]
[DOMObject]
public sealed class Attr : Node, INotifyPropertyChanged, IEventTarget, IDisposable, IXPathNSResolver

Inheritance

objectDOMObjectEventTargetNodeAttr

Implements

INotifyPropertyChanged, IEventTarget, IDisposable, IXPathNSResolver

Inherited Members

Node.ELEMENT_NODE, Node.ATTRIBUTE_NODE, Node.TEXT_NODE, Node.CDATA_SECTION_NODE, Node.ENTITY_REFERENCE_NODE, Node.ENTITY_NODE, Node.PROCESSING_INSTRUCTION_NODE, Node.COMMENT_NODE, Node.DOCUMENT_NODE, Node.DOCUMENT_TYPE_NODE, Node.DOCUMENT_FRAGMENT_NODE, Node.NOTATION_NODE, Node.HasChildNodes(), Node.Normalize(), Node.CloneNode(), Node.CloneNode(bool), Node.IsEqualNode(Node), Node.IsSameNode(Node), Node.LookupPrefix(string), Node.LookupNamespaceURI(string), Node.IsDefaultNamespace(string), Node.InsertBefore(Node, Node), Node.ReplaceChild(Node, Node), Node.RemoveChild(Node), Node.AppendChild(Node), Node.ToString(), Node.NodeType, Node.LocalName, Node.NamespaceURI, Node.Prefix, Node.NodeName, Node.BaseURI, Node.OwnerDocument, Node.ParentNode, Node.ParentElement, Node.ChildNodes, Node.FirstChild, Node.LastChild, Node.PreviousSibling, Node.NextSibling, Node.NodeValue, Node.TextContent, EventTarget.AddEventListener(string, DOMEventHandler, bool), EventTarget.AddEventListener(string, IEventListener), EventTarget.AddEventListener(string, IEventListener, bool), EventTarget.RemoveEventListener(string, DOMEventHandler, bool), EventTarget.RemoveEventListener(string, IEventListener), EventTarget.RemoveEventListener(string, IEventListener, bool), EventTarget.DispatchEvent(Event), EventTarget.Dispose(), DOMObject.GetPlatformType(), object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

Properties

LocalName

Returns the local part of the qualified name of this node. For nodes of any type other than ELEMENT_NODE and ATTRIBUTE_NODE and nodes created with a DOM Level 1 method, such as Document.createElement(), this is always null.

public override string LocalName { get; }

Property Value

string

Name

Returns the name of this attribute.

[DOMName("name")]
public string Name { get; }

Property Value

string

NamespaceURI

The namespace URI of this node, or null if it is unspecified.

public override string NamespaceURI { get; }

Property Value

string

NodeName

The name of this node, depending on its type.

public override string NodeName { get; }

Property Value

string

NodeType

A code representing the type of the underlying object.

public override ushort NodeType { get; }

Property Value

ushort

NodeValue

The value of this node, depending on its type.

public override string NodeValue { get; set; }

Property Value

string

OwnerElement

The Element node this attribute is attached to or null if this attribute is not in use.

[DOMName("ownerElement")]
public Element OwnerElement { get; }

Property Value

Element

Prefix

The namespace prefix of this node, or null if it is unspecified. When it is defined to be null, setting it has no effect

public override string Prefix { get; }

Property Value

string

Specified

True if this attribute was explicitly given a value in the instance document, false otherwise.

[DOMName("specified")]
public bool Specified { get; }

Property Value

bool

TextContent

This attribute returns the text content of this node and its descendants. When it is defined to be null, setting it has no effect. On setting, any possible children this node may have are removed and, if it the new string is not empty or null, replaced by a single Text node containing the string this attribute is set to.

public override string TextContent { get; set; }

Property Value

string

Value

On retrieval, the value of the attribute is returned as a string.

[DOMName("value")]
public string Value { get; set; }

Property Value

string

Methods

Dispose(bool)

Releases unmanaged and - optionally - managed resources.

protected override void Dispose(bool disposing)

Parameters

disposing bool

true to release both managed and unmanaged resources; false to release only unmanaged resources.