Represents a Range header value.
Assembly: System.Net.Http (in System.Net.Http.dll)
Thetype exposes the following members.
|RangeHeaderValue()||Initializes a new instance of the class.|
|RangeHeaderValue(Nullable<Int64>, Nullable<Int64>)||Initializes a new instance of the class with a byte range.|
|Equals||Determines whether the specified Object is equal to the current 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 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 instance.|
|ToString||Returns a string that represents the current object. (Overrides Object.ToString().)|
|TryParse||Determines whether a string is valid information.|
The class provides support for the Range header as defined in RFC 2616 by the IETF.
Since all HTTP entities are represented in HTTP messages as sequences of bytes, the concept of a byte range is meaningful for any HTTP entity. However, not all clients and servers need to support byte-range operations.
The Range header on a request allows a client to request that it only wants to receive some part of the specified range of bytes in an HTTP entity. Servers are not required to support Range header requests.
An example of a Range header in an HTTP protocol request that requests the first 100 bytes would be would be the following:
A HTTP server indicates support for Range headers with the Accept-Ranges header. An example of the Accept-Ranges header from a server that supports byte-ranges would be as follows:
If an Accept-Ranges header is not received in the header of the response from the server, then the server does not support Range headers. An example of the Accept-Ranges header from a server that does not support ranges, but recognizes the Accept-Ranges header, would be as follows:
Windows Phone 8.1, Windows 8.1, Windows Server 2012 R2, 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.