Type Aliasswift-nio 2.84.0NIOHTTP1
OutboundOut
NIOHTTPClientUpgradeHandler.swift:96typealias OutboundOut = HTTPClientRequestPart
typealias OutboundOut = HTTPClientRequestPart
import NIOHTTP1
final class NIOHTTPClientUpgradeHandler
A client-side channel handler that sends a HTTP upgrade handshake request to perform a HTTP-upgrade. When the first HTTP request is sent, this handler will add all appropriate headers to perform an upgrade to the a protocol. It may add headers for a set of protocols in preference order. If the upgrade fails (i.e. response is not 101 Switching Protocols), this handler simply removes itself from the pipeline. If the upgrade is successful, it upgrades the pipeline to the new protocol.
typealias HTTPClientRequestPart = HTTPPart<HTTPRequestHead, IOData>
The components of a HTTP request from the view of a HTTP client.
convenience init(upgraders: [any NIOHTTPClientProtocolUpgrader], httpHandlers: [any RemovableChannelHandler], upgradeCompletionHandler: @escaping (ChannelHandlerContext) -> Void)
Create a HTTPClientUpgradeHandler
.
func channelRead(context: ChannelHandlerContext, data: NIOAny)
func write(context: ChannelHandlerContext, data: NIOAny, promise: EventLoopPromise<Void>?)
typealias InboundIn = HTTPClientResponsePart
typealias InboundOut = HTTPClientResponsePart
typealias OutboundIn = HTTPClientRequestPart