Table of Contents

Class HttpHeaders

Namespace
System.Net.Http.Headers
Assembly
System.Net.Http.dll

A collection of headers and their values as defined in RFC 2616.

public abstract class HttpHeaders
Inheritance
HttpHeaders
Derived
Inherited Members
Extension Methods

Constructors

HttpHeaders()

Initializes a new instance of the HttpHeaders class.

protected HttpHeaders()

Methods

Add(string, string)

Adds the specified header and its value into the HttpHeaders collection.

public void Add(string name, string value)

Parameters

name string

The header to add to the collection.

value string

The content of the header.

Exceptions

ArgumentNullException

The values cannot be null or empty.