Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 16 for bottom (0.15 sec)

  1. docs/contribute/concurrency.md

    The HttpURLConnection API is a blocking API. You make a blocking write to send a request, and a blocking read to receive the response.
    
    #### Blocking APIs
    
    Blocking APIs are convenient because you get top-to-bottom procedural code without indirection. Network calls work like regular method calls: ask for data and it is returned. If the request fails, you get a stacktrace right where the call was made.
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Feb 06 16:35:36 GMT 2022
    - 7K bytes
    - Viewed (0)
  2. okhttp/src/main/kotlin/okhttp3/internal/idn/IdnaMappingTable.kt

     *
     * ```
     *  0..63 : Length of the UTF-16 sequence that this range maps to. The offset is b2b3.
     * 64..79 : Offset by a fixed negative offset. The bottom 4 bits of b1 are the top 4 bits of the offset.
     * 80..95 : Offset by a fixed positive offset. The bottom 4 bits of b1 are the top 4 bits of the offset.
     *    119 : Ignored.
     *    120 : Valid.
     *    121 : Disallowed
     *    122 : Mapped inline to the sequence: [b2].
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Tue Apr 02 11:39:58 GMT 2024
    - 9K bytes
    - Viewed (0)
  3. okhttp/src/test/java/okhttp3/ServerTruncatesRequestTest.kt

        val requestBody =
          object : RequestBody() {
            override fun contentType(): MediaType? = null
    
            override fun writeTo(sink: BufferedSink) {
              throw IOException("boom") // Despite this exception, 'sink' is healthy.
            }
          }
    
        val callA =
          client.newCall(
            Request(
              url = server.url("/"),
              body = requestBody,
            ),
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 9.5K bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/URLConnectionTest.kt

        client =
          client.newBuilder()
            .dns { hostname: String? -> throw RuntimeException("boom!") }
            .build()
        server.enqueue(MockResponse())
        assertFailsWith<RuntimeException> {
          getResponse(newRequest("/"))
        }.also { expected ->
          assertThat(expected.message).isEqualTo("boom!")
        }
      }
    
      @Test
      fun streamedBodyIsRetriedOnHttp2Shutdown() {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Jan 20 10:30:28 GMT 2024
    - 131.7K bytes
    - Viewed (0)
  5. okhttp/src/test/java/okhttp3/internal/io/FaultyFileSystem.kt

        target: Path,
      ) {
        if (renameFaults.contains(source) || renameFaults.contains(target)) throw IOException("boom!")
        super.atomicMove(source, target)
      }
    
      @Throws(IOException::class)
      override fun delete(
        path: Path,
        mustExist: Boolean,
      ) {
        if (deleteFaults.contains(path)) throw IOException("boom!")
        super.delete(path, mustExist)
      }
    
      @Throws(IOException::class)
      override fun deleteRecursively(
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 2.8K bytes
    - Viewed (0)
  6. okhttp/src/test/java/okhttp3/InterceptorTest.kt

       * exception goes to the uncaught exception handler.
       */
      private fun interceptorThrowsRuntimeExceptionAsynchronous(network: Boolean) {
        val boom = RuntimeException("boom!")
        addInterceptor(network) { chain: Interceptor.Chain? -> throw boom }
        val executor = ExceptionCatchingExecutor()
        client =
          client.newBuilder()
            .dispatcher(Dispatcher(executor))
            .build()
        val request =
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sun Jan 14 10:20:09 GMT 2024
    - 27.8K bytes
    - Viewed (0)
  7. okhttp/src/test/java/okhttp3/internal/concurrent/TaskRunnerRealBackendTest.kt

      }
    
      @Test fun taskFailsWithUncheckedException() {
        queue.schedule("task", TimeUnit.MILLISECONDS.toNanos(100)) {
          log.put("failing task running")
          throw RuntimeException("boom!")
        }
    
        queue.schedule("task", TimeUnit.MILLISECONDS.toNanos(200)) {
          log.put("normal task running")
          return@schedule -1L
        }
    
        queue.idleLatch().await(500, TimeUnit.MILLISECONDS)
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 3.5K bytes
    - Viewed (0)
  8. okhttp/src/test/java/okhttp3/internal/ws/WebSocketHttpTest.kt

        Exception::class,
      )
      fun throwingOnFailLogs() {
        webServer.enqueue(
          MockResponse.Builder()
            .code(200)
            .body("Body")
            .build(),
        )
        val e = RuntimeException("boom")
        clientListener.setNextEventDelegate(
          object : WebSocketListener() {
            override fun onFailure(
              webSocket: WebSocket,
              t: Throwable,
              response: Response?,
            ) {
    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/Cache.kt

     * doesn't cache partial responses.
     *
     * ## Force a Network Response
     *
     * In some situations, such as after a user clicks a 'refresh' button, it may be necessary to skip
     * the cache, and fetch data directly from the server. To force a full refresh, add the `no-cache`
     * directive:
     *
     * ```java
     * Request request = new Request.Builder()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 10 19:46:48 GMT 2024
    - 26.8K bytes
    - Viewed (0)
  10. okhttp/src/test/java/okhttp3/CallTest.kt

      }
    
      @Test
      fun clientReadsHeadersDataTrailersHttp2() {
        platform.assumeHttp2Support()
        server.enqueue(
          MockResponse.Builder()
            .clearHeaders()
            .addHeader("h1", "v1")
            .addHeader("h2", "v2")
            .body("HelloBonjour")
            .trailers(headersOf("trailers", "boom"))
            .build(),
        )
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 10 19:46:48 GMT 2024
    - 142.5K bytes
    - Viewed (0)
Back to top