Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 67 for instanceOf (0.21 sec)

  1. mockwebserver/README.md

      assertEquals("/v1/chat/messages/2", request2.getPath());
    
      RecordedRequest request3 = server.takeRequest();
      assertEquals("/v1/chat/messages/3", request3.getPath());
    
      // Shut down the server. Instances cannot be reused.
      server.shutdown();
    }
    ```
    
    Your unit tests might move the `server` into a field so you can shut it down
    from your test's `tearDown()`.
    
    ### API
    
    #### MockResponse
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Dec 17 15:34:10 GMT 2023
    - 5K bytes
    - Viewed (1)
  2. docs/changelogs/changelog_4x.md

        this because it only occurs if you have proxy configured and you share a connection pool among
        multiple `OkHttpClient` instances.
    
        This particularly-subtle bug was caused by us assigning each `OkHttpClient` instance its own
        `NullProxySelector` when an explicit proxy is configured. But we don't share connections when
        the proxy selectors are different. Ugh!
    
    
    ## Version 4.2.0
    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)
  3. okhttp/src/main/kotlin/okhttp3/ConnectionPool.kt

      internal val delegate: RealConnectionPool,
    ) {
      internal constructor(
        maxIdleConnections: Int = 5,
        keepAliveDuration: Long = 5,
        timeUnit: TimeUnit = TimeUnit.MINUTES,
        taskRunner: TaskRunner = TaskRunner.INSTANCE,
        connectionListener: ConnectionListener = ConnectionListener.NONE,
        readTimeoutMillis: Int = 10_000,
        writeTimeoutMillis: Int = 10_000,
        socketConnectTimeoutMillis: Int = 10_000,
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 03 20:39:41 GMT 2024
    - 5.6K bytes
    - Viewed (0)
  4. okhttp/src/main/kotlin/okhttp3/Dns.kt

      companion object {
        /**
         * A DNS that uses [InetAddress.getAllByName] to ask the underlying operating system to
         * lookup IP addresses. Most custom [Dns] implementations should delegate to this instance.
         */
        @JvmField
        val SYSTEM: Dns = DnsSystem()
    
        private class DnsSystem : Dns {
          override fun lookup(hostname: String): List<InetAddress> {
            try {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 2.2K bytes
    - Viewed (0)
  5. okhttp-testing-support/src/main/kotlin/okhttp3/RecordingConnectionListener.kt

        }
      }
    
      /**
       * Remove and return the next event from the recorded sequence.
       *
       * @param eventClass a class to assert that the returned event is an instance of, or null to
       *     take any event class.
       * @param elapsedMs the time in milliseconds elapsed since the immediately-preceding event, or
       *     -1L to take any duration.
       */
      fun takeEvent(
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 5.6K bytes
    - Viewed (0)
  6. samples/slack/src/main/java/okhttp3/slack/SlackApi.java

    import okhttp3.Request;
    import okhttp3.Response;
    import okhttp3.WebSocketListener;
    import okio.ByteString;
    
    /**
     * API access to the <a href="https://api.slack.com/apps">Slack API</a> as an application. One
     * instance of this class may operate without a user, or on behalf of many users. Use the Slack API
     * dashboard to create a client ID and secret for this application.
     *
    Java
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Fri Jul 06 19:30:55 GMT 2018
    - 4.4K bytes
    - Viewed (1)
  7. okhttp/src/test/java/okhttp3/internal/http2/MockHttp2Peer.kt

          }
        }
      }
    
      private fun readAndWriteFrames() {
        check(socket == null)
        val socket = serverSocket!!.accept()!!
        this.socket = socket
    
        // Bail out now if this instance was closed while waiting for the socket to accept.
        synchronized(this) {
          if (executor.isShutdown) {
            socket.close()
            return
          }
        }
        val outputStream = socket.getOutputStream()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Thu Apr 11 22:09:35 GMT 2024
    - 8.7K bytes
    - Viewed (0)
  8. docs/features/events.md

    the preceding example we used a field, `callStartNanos`, to track the elapsed time of each event. This is handy, but it won’t work if multiple calls are executing concurrently. To accommodate this, use a `Factory` to create a new `EventListener` instance for each `Call`. This allows each listener to keep call-specific state.
    
    This [sample factory](https://github.com/square/okhttp/blob/master/samples/guide/src/main/java/okhttp3/recipes/PrintEvents.java) creates a unique ID for each call...
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Feb 06 02:19:09 GMT 2022
    - 7.7K bytes
    - Viewed (0)
  9. mockwebserver-junit5/src/test/java/mockwebserver3/junit5/internal/ExtensionMultipleInstancesTest.kt

        defaultInstance: MockWebServer,
        @MockWebServerInstance("A") instanceA: MockWebServer,
        @MockWebServerInstance("B") instanceB: MockWebServer,
      ) {
        defaultInstancePort = defaultInstance.port
        instanceAPort = instanceA.port
        instanceBPort = instanceB.port
        assertThat(defaultInstance.started).isTrue()
        assertThat(instanceA.started).isTrue()
        assertThat(instanceB.started).isTrue()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Jan 14 10:20:09 GMT 2024
    - 2.3K bytes
    - Viewed (0)
  10. okhttp-brotli/api/okhttp-brotli.api

    public final class okhttp3/brotli/BrotliInterceptor : okhttp3/Interceptor {
    	public static final field INSTANCE Lokhttp3/brotli/BrotliInterceptor;
    	public fun intercept (Lokhttp3/Interceptor$Chain;)Lokhttp3/Response;
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Feb 26 19:17:33 GMT 2022
    - 220 bytes
    - Viewed (0)
Back to top