Common interface for a set of HTTP headers.
Construct from a collection of [name, value] pairs
Optional
Readonly
Gets the first value for the given name, ignoring any additional values
The header name to look for
The first header value, or default if no values exist
Get the list of values for the given name
List of values, or empty list if none exist
Add a name/value pair
The header name
The header value
Set a name/value pair, replacing any existing values for the name
Removes all values for the given name
The header to remove all values for
Removes a specific name/value pair
The header name to remove
The header value to remove
Clears the entire header set
Iterator. Allows for: let headers = new HttpHeaders(); ... for (const header of headers) { }
Generated using TypeDoc
Common interface for a set of HTTP headers.