- Sort Score
- Result 10 results
- Languages All
Results 31 - 40 of 56 for ResponseBody (0.19 sec)
-
okhttp-testing-support/src/main/kotlin/okhttp3/UppercaseResponseInterceptor.kt
override fun intercept(chain: Chain): Response { return uppercaseResponse(chain.proceed(chain.request())) } private fun uppercaseResponse(response: Response): Response { val uppercaseBody: ResponseBody = object : ForwardingResponseBody(response.body) { override fun source(): BufferedSource { return uppercaseSource(delegate().source()).buffer() } } return response.newBuilder()
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 1.8K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/connection/Exchange.kt
import java.io.IOException import java.net.ProtocolException import java.net.SocketException import okhttp3.EventListener import okhttp3.Headers import okhttp3.Request import okhttp3.Response import okhttp3.ResponseBody import okhttp3.internal.http.ExchangeCodec import okhttp3.internal.http.RealResponseBody import okhttp3.internal.ws.RealWebSocket import okio.Buffer import okio.ForwardingSink import okio.ForwardingSource
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 9.2K bytes - Viewed (2) -
okhttp-logging-interceptor/src/test/java/okhttp3/logging/HttpLoggingInterceptorTest.kt
.post("Uncompressed".toRequestBody().gzip()) .build(), ).execute() val responseBody = response.body assertThat(responseBody.string(), "Expected response body to be valid") .isEqualTo("Uncompressed") responseBody.close() networkLogs .assertLogEqual("--> POST $url http/1.1") .assertLogEqual("Content-Encoding: gzip")
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Sat Apr 06 09:14:38 GMT 2024 - 37.6K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/Call.kt
/** * Invokes the request immediately, and blocks until the response can be processed or is in error. * * To avoid leaking resources callers should close the [Response] which in turn will close the * underlying [ResponseBody]. * * ```java * // ensure the response (and underlying response body) is closed * try (Response response = client.newCall(request).execute()) { * ... * } * ``` *
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Wed Dec 20 23:27:07 GMT 2023 - 3.6K bytes - Viewed (0) -
mockwebserver/src/main/kotlin/mockwebserver3/MockResponseBody.kt
* */ package mockwebserver3 import java.io.IOException import okhttp3.ExperimentalOkHttpApi import okio.BufferedSink /** * The body of a [MockResponse]. * * Unlike [okhttp3.ResponseBody], this interface is designed to be implemented by writers and not * called by readers. */ @ExperimentalOkHttpApi interface MockResponseBody { /** The length of this response in bytes, or -1 if unknown. */
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Tue Jan 23 14:31:42 GMT 2024 - 1.1K bytes - Viewed (0) -
okhttp-brotli/src/test/java/okhttp3/brotli/BrotliBombTest.kt
import assertk.assertions.isNotNull import assertk.assertions.matches import assertk.assertions.message import okhttp3.Protocol import okhttp3.Request import okhttp3.Response import okhttp3.ResponseBody.Companion.toResponseBody import okhttp3.brotli.internal.uncompress import okio.Buffer import okio.BufferedSource import okio.ByteString import okio.ByteString.Companion.decodeHex import okio.IOException
Plain Text - Registered: Fri Mar 29 11:42:11 GMT 2024 - Last Modified: Mon Jan 29 22:50:20 GMT 2024 - 2.9K bytes - Viewed (0) -
okhttp-brotli/src/main/kotlin/okhttp3/brotli/internal/Uncompress.kt
* See the License for the specific language governing permissions and * limitations under the License. */ package okhttp3.brotli.internal import okhttp3.Response import okhttp3.ResponseBody.Companion.asResponseBody import okhttp3.internal.http.promisesBody import okio.GzipSource import okio.buffer import okio.source import org.brotli.dec.BrotliInputStream
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Mon Apr 01 13:19:01 GMT 2024 - 1.5K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/-UtilCommon.kt
*/ @file:Suppress("ktlint:standard:filename") package okhttp3.internal import okhttp3.Headers import okhttp3.RequestBody import okhttp3.RequestBody.Companion.toRequestBody import okhttp3.ResponseBody import okhttp3.ResponseBody.Companion.toResponseBody import okio.ArrayIndexOutOfBoundsException import okio.Buffer import okio.BufferedSink import okio.BufferedSource import okio.ByteString.Companion.decodeHex
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 11K bytes - Viewed (0) -
okhttp-coroutines/src/test/kotlin/okhttp3/SuspendCallTest.kt
Response.Builder() .request(Request("https://example.com/".toHttpUrl())) .protocol(Protocol.HTTP_1_1) .message("OK") .code(200) .body( object : ResponseBody() { override fun contentType() = null override fun contentLength() = -1L override fun source() = object : ForwardingSource(Buffer()) {
Plain Text - Registered: Fri Apr 12 11:42:09 GMT 2024 - Last Modified: Fri Apr 05 11:25:23 GMT 2024 - 5.3K bytes - Viewed (0) -
okhttp-brotli/src/test/java/okhttp3/brotli/BrotliInterceptorTest.kt
import java.io.IOException import kotlin.test.assertFailsWith import okhttp3.MediaType.Companion.toMediaType import okhttp3.Protocol import okhttp3.Request import okhttp3.Response import okhttp3.ResponseBody.Companion.toResponseBody import okhttp3.brotli.internal.uncompress import okio.ByteString import okio.ByteString.Companion.EMPTY import okio.ByteString.Companion.decodeHex import okio.ByteString.Companion.encodeUtf8
Plain Text - Registered: Fri Apr 26 11:42:10 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 4.2K bytes - Viewed (0)