# HtmlAttribute

An immutable attribute, including its namespace and qualified name.

Class 

`OfficeIMO.Html.Dom`

**Namespace**

`OfficeIMO.Html.Dom`

**Assembly**

`OfficeIMO.Html.Core`

**Source revision**

`ba882f6b0d07` with working tree changes

**Source**

[HtmlAttribute.cs:6](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Html.Core/HtmlAttribute.cs#L6)

**Modifiers**

sealed

An immutable attribute, including its namespace and qualified name.

## Inheritance

- object
- HtmlAttribute

## Usage

Explore 2 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

### Returned or exposed by 1

- Property [HtmlElement.Attributes](/api/html-core/officeimo-html-dom-htmlelement/#property-attributes)

### Accepted by parameters 1

- Method [HtmlElement.SetAttribute](/api/html-core/officeimo-html-dom-htmlelement/#method-setattribute-officeimo-html-dom-htmlattribute) parameter `replacement`

Filter members 

Show inherited

## Constructors

`public HtmlAttribute(string name, string value, string? namespaceUri = null)` [#](#constructor-ctor-string-string-string)

[HtmlAttribute.cs:6](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Html.Core/HtmlAttribute.cs#L6)

Creates an attribute without interpreting its value as markup or a URL.

Parameters

**name string required**

**value string required**

**namespaceUri string? = null optional**

## Inherited Methods

`public virtual bool Equals(object? obj)` [#](#method-equals-object)

Inherited from object

Parameters

**obj object? required**

Returns

`bool`

`public virtual int GetHashCode()` [#](#method-gethashcode)

Inherited from object

Returns

`int`

`public Type GetType()` [#](#method-gettype)

Inherited from object

Returns

`Type`

`public virtual string? ToString()` [#](#method-tostring)

Inherited from object

Returns

`string?`

## Properties

`public string Name { get; }` [#](#property-name)

[HtmlAttribute.cs:18](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Html.Core/HtmlAttribute.cs#L18)

Qualified attribute name.

`public string LocalName { get; }` [#](#property-localname)

[HtmlAttribute.cs:20](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Html.Core/HtmlAttribute.cs#L20)

Local name without the namespace prefix.

`public string Prefix { get; }` [#](#property-prefix)

[HtmlAttribute.cs:22](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Html.Core/HtmlAttribute.cs#L22)

Namespace prefix, or an empty string.

`public string NamespaceUri { get; }` [#](#property-namespaceuri)

[HtmlAttribute.cs:24](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Html.Core/HtmlAttribute.cs#L24)

Namespace URI, or an empty string.

`public string Value { get; }` [#](#property-value)

[HtmlAttribute.cs:26](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Html.Core/HtmlAttribute.cs#L26)

Decoded attribute value.

<!-- PowerForge markdown artifact sha256:F49708127BFF7679EFCD2977BA4C598437BDDC9AEA0297579EEDEBDFA5432BD3 -->
