Attr Class
https://dom.spec.whatwg.org/#interface-attr
public sealed class Attr : Node- Inheritance
NodeAttr
Properties
| Name | Description |
|---|---|
| LocalName | Gets the local name of the attribute. |
| Name | The qualified name (https://dom.spec.whatwg.org/#concept-attribute-qualified-name). |
| NamespaceUri | Gets the namespace of the attribute, or null when it has none. |
| NodeName | Gets the qualified name of the attribute. |
| NodeType | Gets the type of the node, which is always ATTRIBUTE_NODE. |
| NodeValue | Gets or sets the value of the attribute. |
| OwnerElement | Gets the element that owns the attribute, or null when the attribute is detached. |
| Prefix | Gets the namespace prefix of the attribute, or null when it has none. |
| Specified | Always true (https://dom.spec.whatwg.org/#dom-attr-specified). |
| TextContent | Gets or sets the value of the attribute. |
| Value | Gets or sets the value of the attribute. |
LocalName
Attr.csGets the local name of the attribute.
public string LocalName { get; }Name
Attr.csThe qualified name (https://dom.spec.whatwg.org/#concept-attribute-qualified-name).
public string Name { get; }NamespaceUri
Attr.csGets the namespace of the attribute, or null when it has none.
public string? NamespaceUri { get; }NodeName
Attr.csNodeType
Attr.csNodeValue
Attr.csOwnerElement
Attr.csGets the element that owns the attribute, or null when the attribute is detached.
public Element? OwnerElement { get; }Prefix
Attr.csGets the namespace prefix of the attribute, or null when it has none.
public string? Prefix { get; }Specified
Attr.csAlways true (https://dom.spec.whatwg.org/#dom-attr-specified).
public bool Specified { get; }TextContent
Attr.csValue
Attr.csGets or sets the value of the attribute.
public string Value { get; set; }