- Sort Score
- Num 10 results
- Language All
Results 1 - 10 of 17 for networkResponse (0.11 seconds)
The search processing time has exceeded the limit. The displayed results may be partial.
-
okhttp/src/jvmTest/kotlin/okhttp3/RecordedResponse.kt
*/ fun networkResponse(): RecordedResponse { val networkResponse = response!!.networkResponse!! return RecordedResponse(networkResponse.request, networkResponse, null, null, null) } /** Asserts that the current response didn't use the network. */ fun assertNoNetworkResponse() = apply { assertThat(response!!.networkResponse).isNull() }Created: Fri Apr 03 11:42:14 GMT 2026 - Last Modified: Fri Dec 27 13:39:56 GMT 2024 - 5.3K bytes - Click Count (0) -
okhttp/src/commonJvmAndroid/kotlin/okhttp3/Response.kt
} open fun socket(socket: Socket) = apply { this.socket = socket } open fun networkResponse(networkResponse: Response?) = apply { checkSupportResponse("networkResponse", networkResponse) this.networkResponse = networkResponse } open fun cacheResponse(cacheResponse: Response?) = apply {Created: Fri Apr 03 11:42:14 GMT 2026 - Last Modified: Mon Jul 28 14:39:28 GMT 2025 - 18.1K bytes - Click Count (0) -
okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/http/BridgeInterceptor.kt
} val networkRequest = requestBuilder.build() val networkResponse = chain.proceed(networkRequest) chain.cookieJar.receiveHeaders(networkRequest.url, networkResponse.headers) val responseBuilder = networkResponse .newBuilder() .request(networkRequest) if (transparentGzip && "gzip".equals(networkResponse.header("Content-Encoding"), ignoreCase = true) &&Created: Fri Apr 03 11:42:14 GMT 2026 - Last Modified: Sun Jan 11 12:06:21 GMT 2026 - 4.2K bytes - Click Count (0) -
okhttp-testing-support/src/main/kotlin/okhttp3/EventListenerAdapter.kt
retry: Boolean, ) = onEvent(RetryDecision(System.nanoTime(), call, exception, retry)) override fun followUpDecision( call: Call, networkResponse: Response, nextRequest: Request?, ) = onEvent(FollowUpDecision(System.nanoTime(), call, networkResponse, nextRequest))
Created: Fri Apr 03 11:42:14 GMT 2026 - Last Modified: Tue Nov 04 19:13:52 GMT 2025 - 7.1K bytes - Click Count (0) -
okhttp/src/commonJvmAndroid/kotlin/okhttp3/EventListener.kt
* * [OkHttpClient.authenticator] must respond to an authorization challenge. * * @param networkResponse the intermediate response that may require a follow-up request. * @param nextRequest the follow-up request that will be made. Null if no follow-up will be made. */ open fun followUpDecision( call: Call, networkResponse: Response, nextRequest: Request?, ) { }
Created: Fri Apr 03 11:42:14 GMT 2026 - Last Modified: Tue Oct 07 21:03:04 GMT 2025 - 24.9K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/InterceptorTest.kt
// The network response also has everything, including the raw gzipped content. val networkResponse = chain.proceed(networkRequest) assertThat(networkResponse.header("Content-Encoding")).isEqualTo("gzip") networkResponse } client = client .newBuilder() .addNetworkInterceptor(interceptor) .build()Created: Fri Apr 03 11:42:14 GMT 2026 - Last Modified: Tue Nov 04 16:11:23 GMT 2025 - 28.2K bytes - Click Count (0) -
okhttp-testing-support/src/main/kotlin/okhttp3/ClientRuleEventListener.kt
override fun retryDecision( call: Call, exception: IOException, retry: Boolean, ) { logWithTime("retryDecision") } override fun followUpDecision( call: Call, networkResponse: Response, nextRequest: Request?, ) { logWithTime("followUpDecision") } private fun logWithTime(message: String) { val startNs = startNs val timeMs =
Created: Fri Apr 03 11:42:14 GMT 2026 - Last Modified: Tue Oct 07 21:03:04 GMT 2025 - 5.4K bytes - Click Count (0) -
okhttp-testing-support/src/main/kotlin/okhttp3/CallEvent.kt
val exception: IOException, val retry: Boolean, ) : CallEvent() data class FollowUpDecision( override val timestampNs: Long, override val call: Call, val networkResponse: Response, val nextRequest: Request?, ) : CallEvent()Created: Fri Apr 03 11:42:14 GMT 2026 - Last Modified: Mon Oct 06 13:40:20 GMT 2025 - 7.4K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/KotlinDeprecationErrorTest.kt
val message: String = response.message() val handshake: Handshake? = response.handshake() val headers: Headers = response.headers() val body: ResponseBody = response.body() val networkResponse: Response? = response.networkResponse() val cacheResponse: Response? = response.cacheResponse() val priorResponse: Response? = response.priorResponse() val cacheControl: CacheControl = response.cacheControl()
Created: Fri Apr 03 11:42:14 GMT 2026 - Last Modified: Fri Dec 27 13:39:56 GMT 2024 - 13.3K bytes - Click Count (0) -
docs/recipes.md
println("Response 1 response: $it") println("Response 1 cache response: ${it.cacheResponse}") println("Response 1 network response: ${it.networkResponse}") return@use it.body!!.string() } val response2Body = client.newCall(request).execute().use { if (!it.isSuccessful) throw IOException("Unexpected code $it")Created: Fri Apr 03 11:42:14 GMT 2026 - Last Modified: Sun Mar 15 09:01:42 GMT 2026 - 47.8K bytes - Click Count (0)