Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 33 for delano (0.19 sec)

  1. okhttp/src/main/kotlin/okhttp3/internal/idn/Punycode.kt

            w *= scaleW
          }
          bias = adapt(i - oldi, codePoints.size + 1, oldi == 0)
          val deltaN = i / (codePoints.size + 1)
          if (n > Int.MAX_VALUE - deltaN) return false // Prevent overflow.
          n += deltaN
          i %= (codePoints.size + 1)
    
          if (n > 0x10ffff) return false // Not a valid code point.
    
          codePoints.add(i, n)
    
          i++
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 03 03:04:50 GMT 2024
    - 8.5K bytes
    - Viewed (0)
  2. samples/guide/src/main/java/okhttp3/recipes/ConfigureTimeouts.java

            .callTimeout(10, TimeUnit.SECONDS)
            .build();
      }
    
      public void run() throws Exception {
        Request request = new Request.Builder()
            .url("http://httpbin.org/delay/2") // This URL is served with a 2 second delay.
            .build();
    
        try (Response response = client.newCall(request).execute()) {
          System.out.println("Response completed: " + response);
        }
      }
    
    Java
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Sep 28 18:00:26 GMT 2019
    - 1.5K bytes
    - Viewed (0)
  3. okhttp/src/main/kotlin/okhttp3/ConnectionPool.kt

        /** How long to wait to retry pre-emptive connection attempts that fail. */
        @JvmField val backoffDelayMillis: Long = 60 * 1000,
        /** How much jitter to introduce in connection retry backoff delays */
        @JvmField val backoffJitterMillis: Int = 100,
      )
    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/test/java/okhttp3/internal/concurrent/TaskRunnerTest.kt

          "FINE: Q10000 finished run in   0 µs: task",
        )
      }
    
      /** Repeat with a delay of 200 but schedule with a delay of 50. The schedule wins. */
      @Test fun executeScheduledEarlierReplacesRepeatedLater() {
        val task =
          object : Task("task") {
            val schedules = mutableListOf(50.µs)
            val delays = mutableListOf(200.µs, -1)
    
            override fun runOnce(): Long {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 29 00:33:04 GMT 2024
    - 23K bytes
    - Viewed (0)
  5. samples/guide/src/main/java/okhttp3/recipes/kt/PerCallSettings.kt

    import okhttp3.Request
    
    class PerCallSettings {
      private val client = OkHttpClient()
    
      fun run() {
        val request =
          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.
        val client1 =
          client.newBuilder()
            .readTimeout(500, TimeUnit.MILLISECONDS)
            .build()
        try {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.7K bytes
    - Viewed (0)
  6. samples/guide/src/main/java/okhttp3/recipes/kt/CancelCall.kt

      private val executor = Executors.newScheduledThreadPool(1)
      private val client = OkHttpClient()
    
      fun run() {
        val request =
          Request.Builder()
            .url("http://httpbin.org/delay/2") // This URL is served with a 2 second delay.
            .build()
    
        val startNanos = System.nanoTime()
        val call = client.newCall(request)
    
        // Schedule a job to cancel the call in 1 second.
        executor.schedule({
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 1.9K bytes
    - Viewed (0)
  7. docs/recipes.md

          private val client = OkHttpClient()
    
          fun run() {
            val request = Request.Builder()
                .url("http://httpbin.org/delay/2") // This URL is served with a 2 second delay.
                .build()
    
            val startNanos = System.nanoTime()
            val call = client.newCall(request)
    
            // Schedule a job to cancel the call in 1 second.
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Fri Feb 18 08:52:22 GMT 2022
    - 40.2K bytes
    - Viewed (1)
  8. mockwebserver/src/test/java/mockwebserver3/MockWebServerTest.kt

        assertThat(inputStream!!.read()).isEqualTo('B'.code)
      }
    
      /**
       * Throttle the request body by sleeping 500ms after every 3 bytes. With a 6-byte request, this
       * should yield one sleep for a total delay of 500ms.
       */
      @Test
      fun throttleRequest() {
        assumeNotWindows()
        server.enqueue(
          MockResponse.Builder()
            .throttleBody(3, 500, TimeUnit.MILLISECONDS)
            .build(),
        )
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 23.5K bytes
    - Viewed (0)
  9. okhttp/src/main/kotlin/okhttp3/internal/platform/AndroidPlatform.kt

    class AndroidPlatform : Platform() {
      private val socketAdapters =
        listOfNotNull(
          StandardAndroidSocketAdapter.buildIfSupported(),
          DeferredSocketAdapter(AndroidSocketAdapter.playProviderFactory),
          // Delay and Defer any initialisation of Conscrypt and BouncyCastle
          DeferredSocketAdapter(ConscryptSocketAdapter.factory),
          DeferredSocketAdapter(BouncyCastleSocketAdapter.factory),
        ).filter { it.isSupported() }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 6.2K bytes
    - Viewed (0)
  10. okhttp/src/test/java/okhttp3/internal/connection/FastFallbackExchangeFinderTest.kt

     *
     * This test uses [TaskFaker] to deterministically test racy code. Each function in this test has
     * the same structure:
     *
     *  * prepare a set of plans, each with a predictable connect delay
     *  * attempt to find a connection
     *  * step through time, asserting that the expected side effects are performed.
     */
    internal class FastFallbackExchangeFinderTest {
      private val taskFaker = TaskFaker()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 24 04:40:49 GMT 2024
    - 20.9K bytes
    - Viewed (0)
Back to top