- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 41 for eventListener (0.16 sec)
-
okhttp/src/main/kotlin/okhttp3/EventListener.kt
* from this method.** */ fun create(call: Call): EventListener } companion object { @JvmField val NONE: EventListener = object : EventListener() { } }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 15.2K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/connection/Exchange.kt
trackFailure(e) } if (requestDone) { if (e != null) { eventListener.requestFailed(call, e) } else { eventListener.requestBodyEnd(call, bytesRead) } } if (responseDone) { if (e != null) { eventListener.responseFailed(call, e) } else { eventListener.responseBodyEnd(call, bytesRead) } }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 9.2K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/connection/RealCall.kt
val forWebSocket: Boolean, ) : Call, Cloneable { internal val lock: ReentrantLock = ReentrantLock() private val connectionPool: RealConnectionPool = client.connectionPool.delegate internal val eventListener: EventListener = client.eventListenerFactory.create(this) private val timeout = object : AsyncTimeout() { override fun timedOut() { ******@****.***() } }.apply {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Apr 20 17:03:43 UTC 2024 - 17.9K bytes - Viewed (0) -
okhttp-logging-interceptor/src/main/kotlin/okhttp3/logging/LoggingEventListener.kt
import java.net.Proxy import java.util.concurrent.TimeUnit import okhttp3.Call import okhttp3.Connection import okhttp3.EventListener import okhttp3.Handshake import okhttp3.HttpUrl import okhttp3.OkHttpClient import okhttp3.Protocol import okhttp3.Request import okhttp3.Response /** * An OkHttp EventListener, which logs call events. Can be applied as an * [event listener factory][OkHttpClient.eventListenerFactory]. *
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Apr 01 11:07:32 UTC 2024 - 5.4K bytes - Viewed (0) -
android-test/src/androidTest/java/okhttp/android/test/alpn/AlpnOverrideTest.kt
listOf( ConnectionSpec.Builder(ConnectionSpec.MODERN_TLS) .supportsTlsExtensions(false) .build(), ), ) .eventListener( object : EventListener() { override fun connectionAcquired( call: Call, connection: Connection, ) { val sslSocket = connection.socket() as SSLSocket
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 2.7K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/connection/CallConnectionUser.kt
internal class CallConnectionUser( private val call: RealCall, private val poolConnectionListener: ConnectionListener, private val chain: RealInterceptorChain, ) : ConnectionUser { private val eventListener: EventListener get() = call.eventListener override fun addPlanToCancel(connectPlan: ConnectPlan) { call.plansToCancel += connectPlan } override fun removePlanToCancel(connectPlan: ConnectPlan) {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Wed Mar 06 17:33:38 UTC 2024 - 3.6K bytes - Viewed (0) -
android-test/src/androidTest/java/okhttp/android/test/OkHttpTest.kt
response.use { assertEquals(200, response.code) } } @Test fun testEventListener() { val eventListener = RecordingEventListener() enableTls() client = client.newBuilder().eventListenerFactory(clientTestRule.wrap(eventListener)).build() server.enqueue(MockResponse(body = "abc1")) server.enqueue(MockResponse(body = "abc2"))
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Jan 20 10:30:28 UTC 2024 - 27K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/ServerTruncatesRequestTest.kt
} val localClient = client.newBuilder().eventListener(eventListener).build() val call1 = localClient.newCall(Request(server.url("/"))) call1.execute().use { response -> assertThat(response.body.string()).isEqualTo("Req1") assertThat(response.handshake).isNotNull() assertThat(response.protocol == Protocol.HTTP_1_1) } eventListener.closed = true
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 9.5K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/cache/CacheInterceptor.kt
val networkRequest = strategy.networkRequest val cacheResponse = strategy.cacheResponse cache?.trackResponse(strategy) val listener = (call as? RealCall)?.eventListener ?: EventListener.NONE if (cacheCandidate != null && cacheResponse == null) { // The cache candidate wasn't applicable. Close it. cacheCandidate.body.closeQuietly() }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Fri Mar 22 07:09:21 UTC 2024 - 10.2K bytes - Viewed (0) -
docs/features/events.md
* The performance of these calls on the underlying network. If the network’s performance isn’t sufficient, you need to either improve the network or use less of it. ### EventListener Subclass [EventListener](https://square.github.io/okhttp/3.x/okhttp/okhttp3/EventListener.html) and override methods for the events you are interested in. In a successful HTTP call with no redirects or retries the sequence of events is described by this flow.
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sun Feb 06 02:19:09 UTC 2022 - 7.7K bytes - Viewed (0)