- Sort Score
- Result 10 results
- Languages All
Results 101 - 110 of 377 for if (0.26 sec)
-
okhttp/src/main/kotlin/okhttp3/internal/platform/android/AndroidCertificateChainCleaner.kt
import okhttp3.internal.SuppressSignatureCheck import okhttp3.internal.tls.CertificateChainCleaner /** * Android implementation of CertificateChainCleaner using direct Android API calls. * Not used if X509TrustManager doesn't implement [X509TrustManager.checkServerTrusted] with * an additional host param. */ internal class AndroidCertificateChainCleaner( private val trustManager: X509TrustManager,
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 2.7K bytes - Viewed (0) -
mockwebserver-deprecated/src/test/java/okhttp3/mockwebserver/MockWebServerTest.kt
val redirect = server.takeRequest() assertThat(redirect.requestLine).isEqualTo("GET /new-path HTTP/1.1") } /** * Test that MockWebServer blocks for a call to enqueue() if a request is made before a mock * response is ready. */ @Test fun dispatchBlocksWaitingForEnqueue() { Thread { try { Thread.sleep(1000)
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 21.9K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/CookieJar.kt
*/ interface CookieJar { /** * Saves [cookies] from an HTTP response to this store according to this jar's policy. * * Note that this method may be called a second time for a single HTTP response if the response * includes a trailer. For this obscure HTTP feature, [cookies] contains only the trailer's * cookies. */ fun saveFromResponse( url: HttpUrl, cookies: List<Cookie>, ) /**
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 2.4K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/MediaTypeJvmTest.kt
override fun MediaType.charsetName(): String? = this.charset()?.name() @Test fun testCharsetNameIsDoubleQuotedAndSingleQuotedAndroid() { val mediaType = "text/plain;charset=\"'utf-8'\"".toMediaType() if (isAndroid) { // Charset.forName("'utf-8'") == UTF-8 assertEquals("UTF-8", mediaType.charsetName()) } else { assertNull(mediaType.charset()) } } @Test fun testDefaultCharset() {
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 3K bytes - Viewed (0) -
okhttp-testing-support/src/main/kotlin/okhttp3/ClientRuleEventListener.kt
) { logWithTime("cacheConditionalHit") delegate.cacheConditionalHit(call, cachedResponse) } private fun logWithTime(message: String) { val startNs = startNs val timeMs = if (startNs == null) { // Event occurred before start, for an example an early cancel. 0L } else { TimeUnit.NANOSECONDS.toMillis(System.nanoTime() - startNs) }
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 6K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/cache/CacheInterceptor.kt
val listener = (call as? RealCall)?.eventListener ?: EventListener.NONE if (cacheCandidate != null && cacheResponse == null) { // The cache candidate wasn't applicable. Close it. cacheCandidate.body.closeQuietly() } // If we're forbidden from using the network and the cache is insufficient, fail. if (networkRequest == null && cacheResponse == null) { return Response.Builder()
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Fri Mar 22 07:09:21 GMT 2024 - 10.2K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/http/CallServerInterceptor.kt
if (HttpMethod.permitsRequestBody(request.method) && requestBody != null) { // If there's a "Expect: 100-continue" header on the request, wait for a "HTTP/1.1 100 // Continue" response before transmitting the request body. If we don't get that, return // what we did get (such as a 4xx response) without ever transmitting the request body.
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 6.3K bytes - Viewed (1) -
okhttp/src/main/kotlin/okhttp3/internal/http2/Http2Writer.kt
val hpackWriter: Hpack.Writer = Hpack.Writer(out = hpackBuffer) @Throws(IOException::class) fun connectionPreface() { this.withLock { if (closed) throw IOException("closed") if (!client) return // Nothing to write; servers don't send connection headers! if (logger.isLoggable(FINE)) { logger.fine(format(">> CONNECTION ${CONNECTION_PREFACE.hex()}")) } sink.write(CONNECTION_PREFACE)
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Sat Apr 20 17:03:43 GMT 2024 - 11.3K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/connection/RouteSelector.kt
url: HttpUrl, proxy: Proxy?, ) { fun selectProxies(): List<Proxy> { // If the user specifies a proxy, try that and only that. if (proxy != null) return listOf(proxy) // If the URI lacks a host (as in "http://</"), don't call the ProxySelector. val uri = url.toUri() if (uri.host == null) return immutableListOf(Proxy.NO_PROXY)
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Wed Mar 06 17:33:38 GMT 2024 - 7.2K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/http2/Http2Reader.kt
handler: Handler, length: Int, flags: Int, streamId: Int, ) { if (streamId != 0) throw IOException("TYPE_SETTINGS streamId != 0") if (flags and FLAG_ACK != 0) { if (length != 0) throw IOException("FRAME_SIZE_ERROR ack frame should be empty!") handler.ackSettings() return } if (length % 6 != 0) throw IOException("TYPE_SETTINGS length % 6 != 0: $length")
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 19.9K bytes - Viewed (0)