Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 18 for Every (0.16 sec)

  1. mockwebserver/src/main/kotlin/mockwebserver3/MockResponse.kt

        fun streamHandler(streamHandler: StreamHandler) =
          apply {
            this.streamHandler = streamHandler
          }
    
        /**
         * Sets the response body to [body], chunked every [maxChunkSize] bytes.
         */
        fun chunkedBody(
          body: Buffer,
          maxChunkSize: Int,
        ) = apply {
          removeHeader("Content-Length")
          headers.add(CHUNKED_BODY_HEADER)
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Tue Jan 23 14:31:42 GMT 2024
    - 13.3K bytes
    - Viewed (1)
  2. mockwebserver-deprecated/src/test/java/okhttp3/mockwebserver/MockWebServerTest.kt

          fail<Any>()
        } catch (expected: IOException) {
        }
        server.url("/b").toUrl().openConnection().getInputStream() // Should succeed.
      }
    
      /**
       * 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()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 21.9K bytes
    - Viewed (0)
  3. okhttp/src/main/kotlin/okhttp3/Headers.kt

       * intended to be used as a metric: smaller headers are more efficient to encode and transmit.
       */
      fun byteCount(): Long {
        // Each header name has 2 bytes of overhead for ': ' and every header value has 2 bytes of
        // overhead for '\r\n'.
        var result = (namesAndValues.size * 2).toLong()
    
        for (i in 0 until namesAndValues.size) {
          result += namesAndValues[i].length.toLong()
        }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 11.5K bytes
    - Viewed (0)
  4. docs/changelogs/changelog_4x.md

        Castle is great! But it's a large dependency (6.5 MiB) and its security provider feature
        impacts VM-wide behavior.
    
     *  New: Reduce contention for applications that make a very high number of concurrent requests.
        Previously OkHttp used its connection pool as a lock when making changes to connections and
        calls. With this change each connection is locked independently.
    
    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)
  5. okhttp/src/test/java/okhttp3/KotlinDeprecationErrorTest.kt

    import okhttp3.tls.internal.TlsUtil.localhost
    import okio.Buffer
    import org.junit.jupiter.api.AfterEach
    import org.junit.jupiter.api.Disabled
    import org.junit.jupiter.api.Test
    
    /**
     * Access every declaration that is deprecated with [DeprecationLevel.ERROR]. Although new Kotlin
     * code shouldn't use these, they're necessary for clients migrating from OkHttp 3.x and this test
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 13.3K bytes
    - Viewed (0)
  6. okhttp/src/main/kotlin/okhttp3/internal/cache/DiskLruCache.kt

     *    value should be used as a placeholder if necessary.
     *
     *  * When an entry is being **edited**, it is not necessary to supply data for every value; values
     *    default to their previous value.
     *
     * Every [edit] call must be matched by a call to [Editor.commit] or [Editor.abort]. Committing is
     * atomic: a read observes the full set of values as they were before or after the commit, but never
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 34.7K bytes
    - Viewed (0)
  7. okhttp/src/main/kotlin/okhttp3/internal/publicsuffix/PublicSuffixDatabase.kt

        // In theory, wildcard rules are not restricted to having the wildcard in the leftmost position.
        // In practice, wildcards are always in the leftmost position. For now, this implementation
        // cheats and does not attempt every possible permutation. Instead, it only considers wildcards
        // in the leftmost position. We assert this fact when we generate the public suffix file. If
        // this assertion ever fails we'll need to refactor this implementation.
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 11.7K bytes
    - Viewed (0)
  8. okhttp/src/test/java/okhttp3/internal/ws/WebSocketHttpTest.kt

        assertThat(server.receivedPingCount()).isEqualTo(0)
        assertThat(server.receivedPongCount()).isEqualTo(0)
        closeWebSockets(webSocket, server)
      }
    
      /**
       * Configure the websocket to send pings every 500 ms. Artificially prevent the server from
       * responding to pings. The client should give up when attempting to send its 2nd ping, at about
       * 1000 ms.
       */
      @Test
      fun unacknowledgedPingFailsConnection() {
    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)
  9. okhttp/src/main/kotlin/okhttp3/internal/http2/Http2Connection.kt

        Settings().apply {
          // Flow control was designed more for servers, or proxies than edge clients. If we are a client,
          // set the flow control window to 16MiB.  This avoids thrashing window updates every 64KiB, yet
          // small enough to avoid blowing up the heap.
          if (builder.client) {
            set(Settings.INITIAL_WINDOW_SIZE, OKHTTP_CLIENT_WINDOW_SIZE)
          }
        }
    
      /**
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 20 17:03:43 GMT 2024
    - 32.6K bytes
    - Viewed (0)
  10. okhttp/src/test/java/okhttp3/KotlinSourceModernTest.kt

    import org.junit.jupiter.api.AfterEach
    import org.junit.jupiter.api.Assumptions.assumeFalse
    import org.junit.jupiter.api.BeforeEach
    import org.junit.jupiter.api.Disabled
    import org.junit.jupiter.api.Test
    
    /**
     * Access every type, function, and property from Kotlin to defend against unexpected regressions in
     * modern 4.0.x kotlin source-compatibility.
     */
    @Suppress(
      "ASSIGNED_BUT_NEVER_ACCESSED_VARIABLE",
      "UNUSED_ANONYMOUS_PARAMETER",
    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)
Back to top