HTTPRequestHead

public struct HTTPRequestHead : Equatable

A representation of the request line and header fields of a HTTP request.

  • Undocumented

    Declaration

    Swift

    public var headers: HTTPHeaders
  • The HTTP method for this request.

    Declaration

    Swift

    public var method: HTTPMethod { get set }
  • uri

    The URI used on this request.

    Declaration

    Swift

    public var uri: String { get set }
  • The version for this HTTP request.

    Declaration

    Swift

    public var version: HTTPVersion { get set }
  • Create a HTTPRequestHead

    Declaration

    Swift

    public init(version: HTTPVersion, method: HTTPMethod, uri: String)

    Parameters

    version

    The version for this HTTP request.

    method

    The HTTP method for this request.

    uri

    The URI used on this request.

  • Declaration

    Swift

    public static func ==(lhs: HTTPRequestHead, rhs: HTTPRequestHead) -> Bool
  • Whether this HTTP request is a keep-alive request: that is, whether the connection should remain open after the request is complete.

    Declaration

    Swift

    public var isKeepAlive: Bool { get }
  • Declaration

    Swift

    public var description: String { get }