StringWithQualityHeaderValue Class
Represents a string header value with an optional quality.
Namespace: System.Net.Http.Headers
Assembly: System.Net.Http (in System.Net.Http.dll)
The StringWithQualityHeaderValue type exposes the following members.
| Name | Description | |
|---|---|---|
![]() ![]() | StringWithQualityHeaderValue(String) | Initializes a new instance of the StringWithQualityHeaderValue class. |
![]() ![]() | StringWithQualityHeaderValue(String, Double) | Initializes a new instance of the StringWithQualityHeaderValue class. |
| Name | Description | |
|---|---|---|
![]() ![]() | Equals | Determines whether the specified Object is equal to the current StringWithQualityHeaderValue object. (Overrides Object.Equals(Object).) |
![]() ![]() | Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) |
![]() ![]() | GetHashCode | Serves as a hash function for an StringWithQualityHeaderValue object. (Overrides Object.GetHashCode().) |
![]() ![]() | GetType | Gets the Type of the current instance. (Inherited from Object.) |
![]() ![]() | MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) |
![]() ![]() ![]() | Parse | Converts a string to an StringWithQualityHeaderValue instance. |
![]() ![]() | ToString | Returns a string that represents the current StringWithQualityHeaderValue object. (Overrides Object.ToString().) |
![]() ![]() ![]() | TryParse | Determines whether a string is valid StringWithQualityHeaderValue information. |
| Name | Description | |
|---|---|---|
![]() ![]() | ICloneable.Clone | Creates a new object that is a copy of the current StringWithQualityHeaderValue instance. |
The StringWithQualityHeaderValue class provides support for strings with a quality factor used in some headers as defined in RFC 2616 by the IETF.
Quality factors allow the user agent to indicate the relative degree of preference for various options in various headers including the Accept, Accept-Charset, Accept-Encoding, and Accept-Language headers. Quality uses a scale from 0 to 1. The default value is q=1.
Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.






