Hearken Documentation Beta

Enumeration HTTPHeader

public enum HTTPHeader

An HTTP header.

This is a collection of some commonly used headers but any header can be created using .custom(name: String, value: String).

Nested Types

HTTPHeader.ContentType

Values for the Content-Type HTTP header.

Enumeration Cases

content​Type

case contentType(: ContentType)

Content-Type HTTP header.

content​Length

case contentLength(: Int)

Content-Length HTTP header.

custom

case custom(name: String, value: String)

Custom HTTP header name and value.

Properties

raw​Value

var rawValue: (name: String, value: String)