Search Options

Results per page
Sort
Preferred Languages
Advance

Results 81 - 90 of 153 for Oadd (0.19 sec)

  1. okhttp/src/test/java/okhttp3/HeadersKotlinTest.kt

          pairs += name to value
        }
    
        assertThat(pairs).containsExactly("a" to "b", "c" to "d")
      }
    
      @Test fun builderGetOperator() {
        val builder = Headers.Builder()
        builder.add("a", "b")
        builder.add("c", "d")
        assertThat(builder["a"]).isEqualTo("b")
        assertThat(builder["c"]).isEqualTo("d")
        assertThat(builder["e"]).isNull()
      }
    
      @Test fun builderSetOperator() {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Thu Dec 21 01:54:49 GMT 2023
    - 2K bytes
    - Viewed (0)
  2. okhttp-testing-support/src/main/kotlin/okhttp3/OkHttpClientTestRule.kt

              }
    
            if (recorded) {
              synchronized(clientEventsList) {
                clientEventsList.add(record.message)
    
                if (record.loggerName == "javax.net.ssl") {
                  val parameters = record.parameters
    
                  if (parameters != null) {
                    clientEventsList.add(parameters.first().toString())
                  }
                }
              }
            }
          }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 10.5K bytes
    - Viewed (0)
  3. okhttp-testing-support/src/main/kotlin/okhttp3/RecordingHostnameVerifier.kt

      @JvmField
      val calls: MutableList<String> = mutableListOf()
    
      @Synchronized override fun verify(
        hostname: String,
        session: SSLSession,
      ): Boolean {
        calls.add("verify $hostname")
        return true
      }
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 980 bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/CallKotlinTest.kt

      @Test fun connectExceptionsAreReturnedAsSuppressed() {
        val proxySelector = RecordingProxySelector()
        proxySelector.proxies.add(Proxy(Proxy.Type.HTTP, TestUtil.UNREACHABLE_ADDRESS_IPV4))
        proxySelector.proxies.add(Proxy.NO_PROXY)
        server.shutdown()
    
        client =
          client.newBuilder()
            .proxySelector(proxySelector)
            .readTimeout(Duration.ofMillis(100))
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 20 10:30:28 GMT 2024
    - 8.4K bytes
    - Viewed (0)
  5. okhttp/src/test/java/okhttp3/SocksProxy.kt

          try {
            val fromSource = from.source().buffer()
            val fromSink = from.sink().buffer()
            hello(fromSource, fromSink)
            acceptCommand(from.inetAddress, fromSource, fromSink)
            openSockets.add(from)
          } catch (e: IOException) {
            logger.log(Level.WARNING, "$name failed", e)
            from.closeQuietly()
          }
        }
      }
    
      private fun hello(
        fromSource: BufferedSource,
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Thu Apr 11 22:09:35 GMT 2024
    - 7.7K bytes
    - Viewed (0)
  6. okhttp/src/test/java/okhttp3/KotlinSourceModernTest.kt

      }
    
      @Test
      fun headersBuilder() {
        var builder: Headers.Builder = Headers.Builder()
        builder = builder.add("")
        builder = builder.add("", "")
        builder = builder.addUnsafeNonAscii("", "")
        builder = builder.addAll(headersOf())
        builder = builder.add("", Date(0L))
        builder = builder.add("", Instant.EPOCH)
        builder = builder.set("", "")
        builder = builder.set("", Date(0L))
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 01 14:21:25 GMT 2024
    - 46.5K bytes
    - Viewed (4)
  7. okhttp-testing-support/src/main/kotlin/okhttp3/internal/duplex/AsyncRequestBody.kt

      private val requestBodySinks: BlockingQueue<BufferedSink> = LinkedBlockingQueue()
    
      override fun contentType(): MediaType? = null
    
      override fun writeTo(sink: BufferedSink) {
        requestBodySinks.add(sink)
      }
    
      override fun isDuplex(): Boolean = true
    
      @Throws(InterruptedException::class)
      fun takeSink(): BufferedSink {
        return requestBodySinks.poll(5, SECONDS) ?: throw AssertionError("no sink to take")
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Dec 20 23:27:07 GMT 2023
    - 1.5K bytes
    - Viewed (0)
  8. okhttp/src/main/kotlin/okhttp3/internal/ws/RealWebSocket.kt

        queueSize += data.size.toLong()
        messageAndCloseQueue.add(Message(formatOpcode, data))
        runWriter()
        return true
      }
    
      @Synchronized fun pong(payload: ByteString): Boolean {
        // Don't send pongs after we've failed or sent the close frame.
        if (failed || enqueuedClose && messageAndCloseQueue.isEmpty()) return false
    
        pongQueue.add(payload)
        runWriter()
        return true
      }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 01 14:21:25 GMT 2024
    - 22.1K bytes
    - Viewed (0)
  9. okhttp-tls/src/main/kotlin/okhttp3/tls/HandshakeCertificates.kt

        }
    
        /**
         * Add a trusted root certificate to use when authenticating a peer. Peers must provide
         * a chain of certificates whose root is one of these.
         */
        fun addTrustedCertificate(certificate: X509Certificate) =
          apply {
            this.trustedCertificates += certificate
          }
    
        /**
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 8.5K bytes
    - Viewed (1)
  10. docs/features/interceptors.md

     * Access to the `Connection` that carries the request.
    
    ### Rewriting Requests
    
    Interceptors can add, remove, or replace request headers. They can also transform the body of those requests that have one. For example, you can use an application interceptor to add request body compression if you're connecting to a webserver known to support it.
    
    ```java
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Feb 06 02:19:09 GMT 2022
    - 8.1K bytes
    - Viewed (0)
Back to top