Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 47 for HTTP_1_1 (0.39 sec)

  1. okhttp/src/main/kotlin/okhttp3/Connection.kt

       * HTTPS.
       */
      fun handshake(): Handshake?
    
      /**
       * Returns the protocol negotiated by this connection, or [Protocol.HTTP_1_1] if no protocol
       * has been negotiated. This method returns [Protocol.HTTP_1_1] even if the remote peer is using
       * [Protocol.HTTP_1_0].
       */
      fun protocol(): Protocol
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Dec 20 23:27:07 GMT 2023
    - 4.3K bytes
    - Viewed (0)
  2. okhttp/src/main/kotlin/okhttp3/Protocol.kt

       *
       * This version of OkHttp implements [RFC 7230][rfc_7230], and tracks revisions to that spec.
       *
       * [rfc_7230]: https://tools.ietf.org/html/rfc7230
       */
      HTTP_1_1("http/1.1"),
    
      /**
       * Chromium's binary-framed protocol that includes header compression, multiplexing multiple
       * requests on the same socket, and server-push. HTTP/1.1 semantics are layered on SPDY/3.
       *
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 06 04:17:33 GMT 2024
    - 4.4K bytes
    - Viewed (0)
  3. okhttp/src/test/java/okhttp3/internal/http/ExternalHttp2Example.kt

    import okhttp3.Request
    
    object ExternalHttp2Example {
      @JvmStatic
      fun main(args: Array<String>) {
        val client =
          OkHttpClient.Builder()
            .protocols(listOf(Protocol.HTTP_2, Protocol.HTTP_1_1))
            .build()
        val call =
          client.newCall(
            Request.Builder()
              .url("https://www.google.ca/")
              .build(),
          )
        val response = call.execute()
        try {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.4K bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/internal/http/CancelTest.kt

    import okhttp3.DelegatingServerSocketFactory
    import okhttp3.DelegatingSocketFactory
    import okhttp3.MediaType
    import okhttp3.OkHttpClient
    import okhttp3.OkHttpClientTestRule
    import okhttp3.Protocol.HTTP_1_1
    import okhttp3.RecordingEventListener
    import okhttp3.Request
    import okhttp3.RequestBody
    import okhttp3.SimpleProvider
    import okhttp3.internal.http.CancelTest.CancelMode.CANCEL
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 20 10:30:28 GMT 2024
    - 9.9K bytes
    - Viewed (0)
  5. okhttp/src/main/kotlin/okhttp3/internal/http2/ErrorCode.kt

      FRAME_SIZE_ERROR(6),
    
      REFUSED_STREAM(7),
    
      CANCEL(8),
    
      COMPRESSION_ERROR(9),
    
      CONNECT_ERROR(0xa),
    
      ENHANCE_YOUR_CALM(0xb),
    
      INADEQUATE_SECURITY(0xc),
    
      HTTP_1_1_REQUIRED(0xd),
      ;
    
      companion object {
        fun fromHttp2(code: Int): ErrorCode? = values().find { it.httpCode == code }
      }
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.2K bytes
    - Viewed (0)
  6. regression-test/src/androidTest/java/okhttp/regression/compare/ApacheHttpClientTest.kt

        val request = HttpGet("https://google.com/robots.txt")
    
        httpClient.execute(request).use { response ->
          assertEquals(200, response.code)
          // TODO enable ALPN later
          assertEquals(HttpVersion.HTTP_1_1, response.version)
        }
      }
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.5K bytes
    - Viewed (0)
  7. okhttp/src/test/java/okhttp3/ConnectionListenerTest.kt

          "ConnectionReleased",
        )
      }
    
      @Test
      @Throws(IOException::class)
      fun secondCallEventSequence() {
        enableTls()
        server!!.protocols = listOf(Protocol.HTTP_2, Protocol.HTTP_1_1)
        server!!.enqueue(MockResponse())
        server!!.enqueue(MockResponse())
    
        client.newCall(Request(server!!.url("/")))
          .execute().close()
    
        client.newCall(Request(server!!.url("/")))
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 20 10:30:28 GMT 2024
    - 9.6K bytes
    - Viewed (0)
  8. okhttp/src/test/java/okhttp3/ConnectionReuseTest.kt

          response!!.closeQuietly()
        }
      }
    
      private fun enableHttps() {
        enableHttpsAndAlpn(Protocol.HTTP_1_1)
      }
    
      private fun enableHttp2() {
        platform.assumeHttp2Support()
        enableHttpsAndAlpn(Protocol.HTTP_2, Protocol.HTTP_1_1)
      }
    
      private fun enableHttpsAndAlpn(vararg protocols: Protocol) {
        client =
          client.newBuilder()
            .sslSocketFactory(
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 12.3K bytes
    - Viewed (0)
  9. okhttp/src/main/kotlin/okhttp3/Interceptor.kt

     *   override fun intercept(chain: Interceptor.Chain): Response {
     *     if (myConfig.isInvalid()) {
     *       return Response.Builder()
     *           .request(chain.request())
     *           .protocol(Protocol.HTTP_1_1)
     *           .code(400)
     *           .message("client config invalid")
     *           .body("client config invalid".toResponseBody(null))
     *           .build()
     *     }
     *
     *     return chain.proceed(chain.request())
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 3.5K bytes
    - Viewed (0)
  10. okhttp/src/test/java/okhttp3/ProtocolTest.kt

    import org.junit.jupiter.api.Test
    
    class ProtocolTest {
      @Test
      fun testGetKnown() {
        assertThat(get("http/1.0")).isEqualTo(Protocol.HTTP_1_0)
        assertThat(get("http/1.1")).isEqualTo(Protocol.HTTP_1_1)
        assertThat(get("spdy/3.1")).isEqualTo(Protocol.SPDY_3)
        assertThat(get("h2")).isEqualTo(Protocol.HTTP_2)
        assertThat(get("h2_prior_knowledge")).isEqualTo(Protocol.H2_PRIOR_KNOWLEDGE)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Thu Jan 04 05:32:07 GMT 2024
    - 1.9K bytes
    - Viewed (0)
Back to top