Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for chunkedBody (0.16 sec)

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

        }
    
        /**
         * Sets the response body to the UTF-8 encoded bytes of [body],
         * chunked every [maxChunkSize] bytes.
         */
        fun chunkedBody(
          body: String,
          maxChunkSize: Int,
        ): Builder = chunkedBody(Buffer().writeUtf8(body), maxChunkSize)
    
        /** Sets the headers and returns this. */
        fun headers(headers: Headers) =
          apply {
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Tue Jan 23 14:31:42 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  2. mockwebserver/api/mockwebserver3.api

    	public final fun bodyDelay (JLjava/util/concurrent/TimeUnit;)Lmockwebserver3/MockResponse$Builder;
    	public final fun build ()Lmockwebserver3/MockResponse;
    	public final fun chunkedBody (Ljava/lang/String;I)Lmockwebserver3/MockResponse$Builder;
    	public final fun chunkedBody (Lokio/Buffer;I)Lmockwebserver3/MockResponse$Builder;
    	public final fun clearHeaders ()Lmockwebserver3/MockResponse$Builder;
    	public synthetic fun clone ()Ljava/lang/Object;
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Tue Jan 03 21:59:45 UTC 2023
    - 12.7K bytes
    - Viewed (0)
  3. okhttp-logging-interceptor/src/test/java/okhttp3/logging/HttpLoggingInterceptorTest.kt

          .assertNoMoreLogs()
      }
    
      @Test
      fun basicChunkedResponseBody() {
        setLevel(Level.BASIC)
        server.enqueue(
          MockResponse.Builder()
            .chunkedBody("Hello!", 2)
            .setHeader("Content-Type", PLAIN)
            .build(),
        )
        val response = client.newCall(request().build()).execute()
        response.body.close()
        applicationLogs
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Apr 06 09:14:38 UTC 2024
    - 37.6K bytes
    - Viewed (0)
Back to top