- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 14 for body (0.18 sec)
-
okhttp/src/main/kotlin/okhttp3/internal/connection/RealCall.kt
// the call, but they may be accessed by other threads for duplex requests. /** True if this call still has a request body open. */ private var requestBodyOpen = false /** True if this call still has a response body open. */ private var responseBodyOpen = false /** True if there are more exchanges expected for this call. */ private var expectMoreExchanges = true
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Sat Apr 20 17:03:43 GMT 2024 - 17.9K bytes - Viewed (2) -
docs/changelogs/changelog_4x.md
```kotlin val response: Response = call.execute() val multipartReader = MultipartReader(response.body!!) multipartReader.use { while (true) { val part = multipartReader.nextPart() ?: break process(part.headers, part.body) } } ``` * New: `MediaType.parameter()` gets a parameter like `boundary` from a media type like
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Wed Apr 17 13:25:31 GMT 2024 - 25.2K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/publicsuffix/PublicSuffixListGenerator.kt
withContext(Dispatchers.IO) { client.newCall(request).executeAsync().use { response -> fileSystem.sink(publicSuffixListDotDat).buffer().use { sink -> sink.writeAll(response.body.source()) } } } private suspend fun readImportResults(): ImportResults = withContext(Dispatchers.IO) { val sortedRules: SortedSet<ByteString> = TreeSet()
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Thu Apr 18 01:24:38 GMT 2024 - 6K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/http/RetryAndFollowUpInterceptor.kt
} closeActiveExchange = false return response } val followUpBody = followUp.body if (followUpBody != null && followUpBody.isOneShot()) { closeActiveExchange = false return response } response.body.closeQuietly() if (++followUpCount > MAX_FOLLOW_UPS) {
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Apr 15 13:24:48 GMT 2024 - 12.1K bytes - Viewed (4) -
okhttp-coroutines/src/test/kotlin/okhttp3/coroutines/ExecuteAsyncTest.kt
this.server = server } @Test fun suspendCall() { runTest { server.enqueue(MockResponse(body = "abc")) val call = client.newCall(request) call.executeAsync().use { withContext(Dispatchers.IO) { assertThat(it.body.string()).isEqualTo("abc") } } } } @Test fun timeoutCall() { runTest { server.enqueue(
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Thu Apr 18 01:24:38 GMT 2024 - 5.4K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/-ResponseCommon.kt
""".trimMargin(), ) } override fun timeout() = Timeout.NONE override fun close() { } } fun Response.stripBody(): Response { return newBuilder() .body(UnreadableResponseBody(body.contentType(), body.contentLength())) .build() } val Response.commonIsSuccessful: Boolean get() = code in 200..299 fun Response.commonHeaders(name: String): List<String> = headers.values(name)
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Apr 15 13:24:48 GMT 2024 - 5.2K bytes - Viewed (0) -
CHANGELOG.md
url = "https://cash.app/".toHttpUrl(), ) ``` * New: `Response.body` is now non-null. This was generally the case in OkHttp 4.x, but the Kotlin type declaration was nullable to support rare cases like the body on `Response.cacheResponse`, `Response.networkResponse`, and `Response.priorResponse`. In such cases the body is now non-null, but attempts to read its content will fail.
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Thu Apr 18 01:31:39 GMT 2024 - 21.4K bytes - Viewed (0) -
samples/guide/src/main/java/okhttp3/recipes/CheckHandshake.java
.build(); try (Response response = client.newCall(request).execute()) { if (!response.isSuccessful()) throw new IOException("Unexpected code " + response); System.out.println(response.body().string()); } } public static void main(String... args) throws Exception { new CheckHandshake().run(); }
Java - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Apr 15 14:55:09 GMT 2024 - 2.1K bytes - Viewed (0) -
okhttp/api/okhttp.api
public static final field Companion Lokhttp3/MultipartBody$Part$Companion; public final fun -deprecated_body ()Lokhttp3/RequestBody; public final fun -deprecated_headers ()Lokhttp3/Headers; public synthetic fun <init> (Lokhttp3/Headers;Lokhttp3/RequestBody;Lkotlin/jvm/internal/DefaultConstructorMarker;)V public final fun body ()Lokhttp3/RequestBody;
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Apr 15 13:41:01 GMT 2024 - 70.2K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/http2/Http2Stream.kt
* Corresponds to `FLAG_FIN`. * @param flushHeaders true to force flush the response headers. This should be true unless the * response body exists and will be written immediately. */ @Throws(IOException::class) fun writeHeaders( responseHeaders: List<Header>, outFinished: Boolean, flushHeaders: Boolean, ) {
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Sat Apr 20 17:03:43 GMT 2024 - 23.2K bytes - Viewed (1)