Structure
ServerConfiguration.HTTPVersion
An HTTP protocol version the server can advertise and serve.
struct HTTPVersion
Overview
Use http1_1, http2(config:), and http3(config:) to build the set passed to httpVersions.
Topics
Operators
static func == (`Self`, `Self`) -> BoolEquality is by protocol version only: two values are equal when they represent the same HTTP version, ignoring any associated configuration.static func < (borrowing ServerConfiguration.HTTPVersion, borrowing ServerConfiguration.HTTPVersion) -> Bool
Instance Properties
var alpnProtocolID: StringThe Application-Layer Protocol Negotiation (ALPN) protocol identifier.
Instance Methods
func hash(into: inout Hasher)Hashes by protocol version only, consistent with theEquatableconformance above.
Type Properties
static var http1_1: `Self`The HTTP/1.1 protocol version.static var http2: `Self`The HTTP/2 protocol version with default configuration values.static var http3: `Self`The HTTP/3 protocol version with default configuration values.
Type Methods
static func http2(config: HTTP2) -> ServerConfiguration.HTTPVersionThe HTTP/2 protocol version.static func http3(config: HTTP3) -> ServerConfiguration.HTTPVersionThe HTTP/3 protocol version.
Relationships
Conforms To
Swift.ComparableSwift.EquatableSwift.HashableSwift.SendableSwift.SendableMetatype