Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 6 of 6 for addInterceptor (0.17 sec)

  1. okhttp-logging-interceptor/src/test/java/okhttp3/logging/HttpLoggingInterceptorTest.kt

                  else -> chain.proceed(chain.request())
                }
              },
            )
            .addNetworkInterceptor(networkInterceptor)
            .addInterceptor(applicationInterceptor)
            .sslSocketFactory(
              handshakeCertificates.sslSocketFactory(),
              handshakeCertificates.trustManager,
            )
            .hostnameVerifier(hostnameVerifier)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 06 09:14:38 GMT 2024
    - 37.6K bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/DispatcherTest.kt

      }
    
      @Test
      fun synchronousCallAccessors() {
        val ready = CountDownLatch(2)
        val waiting = CountDownLatch(1)
        client =
          client.newBuilder()
            .addInterceptor(
              Interceptor { chain: Interceptor.Chain? ->
                try {
                  ready.countDown()
                  waiting.await()
                } catch (e: InterruptedException) {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Fri Apr 05 03:30:42 GMT 2024
    - 12.7K bytes
    - Viewed (0)
  3. okhttp/src/test/java/okhttp3/OkHttpClientTest.kt

        val interceptor =
          Interceptor { chain: Interceptor.Chain ->
            chain.proceed(chain.request())
          }
        val original = clientTestRule.newClient()
        original.newBuilder()
          .addInterceptor(interceptor)
          .addNetworkInterceptor(interceptor)
          .build()
        assertThat(original.interceptors.size).isEqualTo(0)
        assertThat(original.networkInterceptors.size).isEqualTo(0)
      }
    
      /**
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Mar 31 17:16:15 GMT 2024
    - 13.2K bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/internal/ws/WebSocketHttpTest.kt

      private val random = Random(0)
      private var client =
        clientTestRule.newClientBuilder()
          .writeTimeout(Duration.ofMillis(500))
          .readTimeout(Duration.ofMillis(500))
          .addInterceptor(
            Interceptor { chain: Interceptor.Chain ->
              val response = chain.proceed(chain.request())
              // Ensure application interceptors never see a null body.
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Mar 31 17:16:15 GMT 2024
    - 35.2K bytes
    - Viewed (1)
  5. okhttp/src/test/java/okhttp3/KotlinSourceModernTest.kt

        builder = builder.connectionSpecs(listOf(ConnectionSpec.MODERN_TLS))
        val interceptors: List<Interceptor> = builder.interceptors()
        builder = builder.addInterceptor(Interceptor { TODO() })
        builder = builder.addInterceptor { it: Interceptor.Chain -> TODO() }
        val networkInterceptors: List<Interceptor> = builder.networkInterceptors()
        builder = builder.addNetworkInterceptor(Interceptor { TODO() })
    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)
  6. docs/changelogs/changelog_4x.md

        enable [Brotli compression][brotli], which compresses 5-20% smaller than gzip.
    
        ```
        val client = OkHttpClient.Builder()
            .addInterceptor(BrotliInterceptor)
            .build()
        ```
    
        This artifact has a dependency on Google's Brotli decoder (95 KiB).
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 17 13:25:31 GMT 2024
    - 25.2K bytes
    - Viewed (0)
Back to top