- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 33 for trailersFn (0.1 sec)
-
okhttp/src/main/kotlin/okhttp3/Response.kt
open fun priorResponse(priorResponse: Response?) = commonPriorResponse(priorResponse) @ExperimentalOkHttpApi open fun trailers(trailersFn: (() -> Headers)): Builder = commonTrailers(trailersFn) open fun sentRequestAtMillis(sentRequestAtMillis: Long) = apply { this.sentRequestAtMillis = sentRequestAtMillis }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Jul 06 09:38:30 UTC 2024 - 15.6K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/-ResponseCommon.kt
} fun Response.Builder.commonHeaders(headers: Headers) = apply { this.headers = headers.newBuilder() } fun Response.Builder.commonTrailers(trailersFn: (() -> Headers)) = apply { this.trailersFn = trailersFn } fun Response.Builder.commonBody(body: ResponseBody) = apply { this.body = body } fun Response.Builder.commonNetworkResponse(networkResponse: Response?) =
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Apr 15 13:24:48 UTC 2024 - 5.2K bytes - Viewed (0) -
mockwebserver/src/main/kotlin/mockwebserver3/MockResponse.kt
fun headers(headers: Headers) = apply { this.headers = headers.newBuilder() } /** Sets the trailers and returns this. */ fun trailers(trailers: Headers) = apply { this.trailers = trailers.newBuilder() } /** Sets the socket policy and returns this. */ fun socketPolicy(socketPolicy: SocketPolicy) = apply {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Tue Jan 23 14:31:42 UTC 2024 - 13.3K bytes - Viewed (0) -
mockwebserver-deprecated/src/main/kotlin/okhttp3/mockwebserver/MockResponse.kt
@JvmName("-deprecated_getTrailers") @Deprecated( message = "moved to var", replaceWith = ReplaceWith(expression = "trailers"), level = DeprecationLevel.ERROR, ) fun getTrailers(): Headers = trailers fun setTrailers(trailers: Headers) = apply { this.trailers = trailers } @JvmName("-deprecated_getSocketPolicy") @Deprecated( message = "moved to var",
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 7.2K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/ResponseJvmTest.kt
assertThat(response.trailers()).isEmpty() } @Test fun testFailsIfTrailersNotSet() { val response = newResponse("".toResponseBody()) { // All live paths (Http1, Http2) in OkHttp do this trailers { error("trailers not available") } } assertFailsWith<IllegalStateException>(message = "trailers not available") { response.trailers() } }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 3.1K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/http2/Http2Stream.kt
if (flushHeaders) { connection.flush() } } fun enqueueTrailers(trailers: Headers) { this.withLock { check(!sink.finished) { "already finished" } require(trailers.size != 0) { "trailers.size() == 0" } this.sink.trailers = trailers } } fun readTimeout(): Timeout = readTimeout fun writeTimeout(): Timeout = writeTimeout
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Apr 20 17:03:43 UTC 2024 - 23.2K bytes - Viewed (0) -
cmd/streaming-signature-v4.go
// only the last chunk is zero-sized. if len(cr.buffer) == 0 { if cr.debug { fmt.Println("EOF. Reading Trailers:", cr.trailers) } if cr.trailers != nil { err = cr.readTrailers() if cr.debug { fmt.Println("trailers returned:", err, "now:", cr.trailers) } if err != nil { cr.err = err return 0, err } } cr.err = io.EOF return n, cr.err }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu May 16 23:13:47 UTC 2024 - 18.2K bytes - Viewed (0) -
cmd/streaming-v4-unsigned.go
if trailer { // Discard anything unsigned. req.Trailer = make(http.Header) trailers := req.Header.Values(awsTrailerHeader) for _, key := range trailers { req.Trailer.Add(key, "") } } else { req.Trailer = nil } return &s3UnsignedChunkedReader{ trailers: req.Trailer, reader: bufio.NewReader(req.Body), buffer: make([]byte, 64*1024), }, ErrNone }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Sat May 06 02:53:12 UTC 2023 - 6.1K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/http1/Http1ExchangeCodec.kt
private val Request.isChunked: Boolean get() = "chunked".equals(header("Transfer-Encoding"), ignoreCase = true) /** * Received trailers. Null unless the response body uses chunked transfer-encoding and includes * trailers. Undefined until the end of the response body. */ private var trailers: Headers? = null /** Returns true if this connection is closed. */ val isClosed: Boolean get() = state == STATE_CLOSED
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 16.2K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/http2/Http2ExchangeCodec.kt
else -> response.headersContentLength() } } override fun openResponseBodySource(response: Response): Source { return stream!!.source } override fun trailers(): Headers { return stream!!.trailers() } override fun cancel() { canceled = true stream?.closeLater(ErrorCode.CANCEL) } companion object { private const val CONNECTION = "connection"
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 6.9K bytes - Viewed (0)