object Companion
source · line 52public
public companion
Factories that transfer an established transport to structured protocol tasks.
function takeOwnershipAsClient
source · line 57public
public suspend fun <T> takeOwnershipAsClient(transport: T, scope: CoroutineScope, options: Http1ReceiveOptions = Http1ReceiveOptions(), limits: Http1Limits = Http1Limits(), ioTimeouts: HttpIoTimeoutOptions = HttpIoTimeoutOptions(), captureTimings: Boolean = false): AsyncHttp1Connection where T: AsyncByteStream, T: AsyncCloseable
Takes an already-established transport as an HTTP client. The supplied scope owns connection tasks; TCP connection and TLS handshake must already be complete.
type parameter T
source · line 57public
T
parameter options
source · line 60public
options: Http1ReceiveOptions = Http1ReceiveOptions()
parameter scope
source · line 59public
scope: CoroutineScope
parameter ioTimeouts
source · line 62public
ioTimeouts: HttpIoTimeoutOptions = HttpIoTimeoutOptions()
parameter captureTimings
source · line 63public
captureTimings: Boolean = false
parameter transport
source · line 58public
transport: T
parameter limits
source · line 61public
limits: Http1Limits = Http1Limits()
function takeOwnershipAsServer
source · line 81public
public suspend fun <T> takeOwnershipAsServer(transport: T, scope: CoroutineScope, options: Http1ReceiveOptions = Http1ReceiveOptions(), limits: Http1Limits = Http1Limits(), ioTimeouts: HttpIoTimeoutOptions = HttpIoTimeoutOptions()): AsyncHttp1Connection where T: AsyncByteStream, T: AsyncCloseable
Takes an already-established transport as an HTTP server. The supplied scope owns connection tasks; TCP connection and TLS handshake must already be complete.
parameter ioTimeouts
source · line 86public
ioTimeouts: HttpIoTimeoutOptions = HttpIoTimeoutOptions()
parameter transport
source · line 82public
transport: T
type parameter T
source · line 81public
T
parameter limits
source · line 85public
limits: Http1Limits = Http1Limits()
parameter scope
source · line 83public
scope: CoroutineScope
parameter options
source · line 84public
options: Http1ReceiveOptions = Http1ReceiveOptions()