- Sort Score
- Num 10 results
- Language All
Results 1 - 5 of 5 for DelegatingSocketFactory (0.27 seconds)
The search processing time has exceeded the limit. The displayed results may be partial.
-
okhttp-testing-support/src/main/kotlin/okhttp3/DelegatingSocketFactory.kt
import java.net.Socket import javax.net.SocketFactory /** * A [SocketFactory] that delegates calls. Sockets can be configured after creation by * overriding [.configureSocket]. */ open class DelegatingSocketFactory( private val delegate: SocketFactory, ) : SocketFactory() { @Throws(IOException::class) override fun createSocket(): Socket { val socket = delegate.createSocket() return configureSocket(socket)
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Wed Mar 19 19:25:20 GMT 2025 - 2.1K bytes - Click Count (0) -
okhttp-testing-support/src/main/kotlin/okhttp3/SpecificHostSocketFactory.kt
/** * A [SocketFactory] that redirects connections to [defaultAddress] or specific overridden address via [set]. */ class SpecificHostSocketFactory( val defaultAddress: InetSocketAddress?, ) : DelegatingSocketFactory(getDefault()) { private val hostMapping = mutableMapOf<InetAddress, InetSocketAddress>() /** Sets the [real] address for [requested]. */ operator fun set( requested: InetAddress,
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Wed Mar 19 19:25:20 GMT 2025 - 1.7K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/internal/http/ThreadInterruptTest.kt
import java.util.concurrent.TimeUnit import kotlin.test.assertFailsWith import okhttp3.Call import okhttp3.Callback import okhttp3.DelegatingServerSocketFactory import okhttp3.DelegatingSocketFactory import okhttp3.OkHttpClient import okhttp3.OkHttpClientTestRule import okhttp3.Request import okhttp3.RequestBody import okhttp3.Response import okhttp3.mockwebserver.MockResponse
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Tue Nov 04 18:33:48 GMT 2025 - 6.4K bytes - Click Count (0) -
android-test/src/androidTest/java/okhttp/android/test/OkHttpTest.kt
enableTls() server.enqueue(MockResponse(body = "abc")) val sslSocketFactory = client.sslSocketFactory val trustManager = client.x509TrustManager!! val delegatingSocketFactory = object : DelegatingSSLSocketFactory(sslSocketFactory) { override fun configureSocket(sslSocket: SSLSocket): SSLSocket = object : DelegatingSSLSocket(sslSocket) {
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Tue Nov 04 19:13:52 GMT 2025 - 29.9K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/FastFallbackTest.kt
// Yield the first IP address so the second IP address completes first. val firstConnectLatch = CountDownLatch(1) val socketFactory = object : DelegatingSocketFactory(SocketFactory.getDefault()) { var first = true override fun createSocket(): Socket { if (first) { first = false firstConnectLatch.await() }Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Tue Nov 04 19:13:52 GMT 2025 - 10.6K bytes - Click Count (0)