Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 155 for okHttpClient (0.11 sec)

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

          this.fastFallback = okHttpClient.fastFallback
          this.authenticator = okHttpClient.authenticator
          this.followRedirects = okHttpClient.followRedirects
          this.followSslRedirects = okHttpClient.followSslRedirects
          this.cookieJar = okHttpClient.cookieJar
          this.cache = okHttpClient.cache
          this.dns = okHttpClient.dns
          this.proxy = okHttpClient.proxy
          this.proxySelector = okHttpClient.proxySelector
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Apr 06 04:21:33 UTC 2024
    - 52K bytes
    - Viewed (0)
  2. okhttp-dnsoverhttps/src/test/java/okhttp3/dnsoverhttps/DohProviders.kt

    import java.net.UnknownHostException
    import okhttp3.HttpUrl.Companion.toHttpUrl
    import okhttp3.OkHttpClient
    
    /**
     * Temporary registry of known DNS over HTTPS providers.
     *
     * https://github.com/curl/curl/wiki/DNS-over-HTTPS
     */
    object DohProviders {
      private fun buildGoogle(bootstrapClient: OkHttpClient): DnsOverHttps {
        return DnsOverHttps.Builder()
          .client(bootstrapClient)
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Dec 23 10:26:25 UTC 2023
    - 3.8K bytes
    - Viewed (0)
  3. okhttp/src/test/java/okhttp3/OkHttpClientTest.kt

          )
        }
      }
    
      @Test fun testH2PriorKnowledgeOkHttpClientConstructionSuccess() {
        val okHttpClient =
          OkHttpClient.Builder()
            .protocols(listOf(Protocol.H2_PRIOR_KNOWLEDGE))
            .build()
        assertThat(okHttpClient.protocols.size).isEqualTo(1)
        assertThat(okHttpClient.protocols[0]).isEqualTo(Protocol.H2_PRIOR_KNOWLEDGE)
      }
    
      @Test fun nullDefaultProxySelector() {
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sun Mar 31 17:16:15 UTC 2024
    - 13.2K bytes
    - Viewed (0)
  4. docs/recipes.md

        ```java
          private final OkHttpClient client = new OkHttpClient();
    
          public void run() throws Exception {
            Request request = new Request.Builder()
                .url("http://httpbin.org/delay/1") // This URL is served with a 1 second delay.
                .build();
    
            // Copy to customize OkHttp for this request.
            OkHttpClient client1 = client.newBuilder()
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Fri Feb 18 08:52:22 UTC 2022
    - 40.2K bytes
    - Viewed (0)
  5. regression-test/src/androidTest/java/okhttp/regression/IssueReproductionTest.java

     */
    @RunWith(AndroidJUnit4.class)
    public class IssueReproductionTest {
      @Test public void getFailsWithoutAdditionalCert() throws IOException {
        OkHttpClient client = new OkHttpClient();
    
        sendRequest(client, "https://google.com/robots.txt");
      }
    
      private void sendRequest(OkHttpClient client, String url) throws IOException {
        Request request = new Request.Builder()
                .url(url)
                .build();
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jul 26 06:37:08 UTC 2021
    - 1.9K bytes
    - Viewed (0)
  6. okhttp-tls/README.md

    Entrust and Verisign.
    
    This is the behavior you'll get with your OkHttpClient if you don't specifically configure
    `HandshakeCertificates`. Or you can do it explicitly with `addPlatformTrustedCertificates()`:
    
    ```java
    HandshakeCertificates clientCertificates = new HandshakeCertificates.Builder()
        .addPlatformTrustedCertificates()
        .build();
    OkHttpClient client = new OkHttpClient.Builder()
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sun Dec 17 15:34:10 UTC 2023
    - 9.1K bytes
    - Viewed (0)
  7. regression-test/src/androidTest/java/okhttp/regression/LetsEncryptTest.java

     * for background.
     */
    @RunWith(AndroidJUnit4.class)
    public class LetsEncryptTest {
      @Test public void getFailsWithoutAdditionalCert() throws IOException {
        OkHttpClient client = new OkHttpClient();
    
        boolean androidMorEarlier = Build.VERSION.SDK_INT <= 23;
        try {
          sendRequest(client, "https://valid-isrgrootx1.letsencrypt.org/robots.txt");
          if (androidMorEarlier) {
            fail();
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Tue Nov 17 07:40:31 UTC 2020
    - 6.1K bytes
    - Viewed (0)
  8. okhttp-brotli/src/test/java/okhttp3/brotli/BrotliTestMain.kt

     */
    package okhttp3.brotli
    
    import okhttp3.OkHttpClient
    import okhttp3.Request
    
    fun main() {
      val client =
        OkHttpClient.Builder()
          .addInterceptor(BrotliInterceptor)
          .build()
    
      sendRequest("https://httpbin.org/brotli", client)
      sendRequest("https://httpbin.org/gzip", client)
    }
    
    private fun sendRequest(
      url: String,
      client: OkHttpClient,
    ) {
      val req = Request.Builder().url(url).build()
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 1.1K bytes
    - Viewed (0)
  9. docs/changelogs/upgrading_to_okhttp_4.md

    
    Backwards-Incompatible Changes
    ------------------------------
    
    #### OkHttpClient final methods
    
    `OkHttpClient` has 26 accessors like `interceptors()` and `writeTimeoutMillis()` that were non-final
    in OkHttp 3.x and are final in 4.x. These were made non-final for use with mocking frameworks like
    [Mockito][mockito]. We believe subtyping `OkHttpClient` is the wrong way to test with OkHttp. If
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sun Feb 06 16:58:16 UTC 2022
    - 10.9K bytes
    - Viewed (0)
  10. okhttp-urlconnection/src/main/kotlin/okhttp3/JavaNetAuthenticator.kt

    package okhttp3
    
    import java.io.IOException
    import okhttp3.Authenticator.Companion.JAVA_NET_AUTHENTICATOR
    
    /**
     * Do not use this.
     *
     * Instead, configure your OkHttpClient.Builder to use `Authenticator.JAVA_NET_AUTHENTICATOR`:
     *
     * ```
     *   val okHttpClient = OkHttpClient.Builder()
     *     .authenticator(okhttp3.Authenticator.Companion.JAVA_NET_AUTHENTICATOR)
     *     .build()
     * ```
     */
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 1.3K bytes
    - Viewed (0)
Back to top