- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 224 for body (0.16 sec)
-
cmd/bucket-lifecycle-handlers_test.go
} if testCase.shouldPass && !bytes.Equal(testCase.lifecycleResponse, rec.Body.Bytes()) { t.Errorf("Test %d: %s: Expected the response to be `%s`, but instead found `%s`", i+1, instanceType, string(testCase.lifecycleResponse), rec.Body.String()) } errorResponse := APIErrorResponse{} err = xml.Unmarshal(rec.Body.Bytes(), &errorResponse) if err != nil && !testCase.shouldPass {
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Tue Jun 13 20:52:33 GMT 2023 - 11.2K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/MultipartBodyTest.kt
assertThat(body.boundary).isEqualTo("123") assertThat(body.type).isEqualTo(MultipartBody.MIXED) assertThat(body.contentType().toString()) .isEqualTo("multipart/mixed; boundary=123") assertThat(body.parts.size).isEqualTo(1) assertThat(body.contentLength()).isEqualTo(33L) val buffer = Buffer() body.writeTo(buffer) assertThat(body.contentLength()).isEqualTo(buffer.size)
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 10.4K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/RequestTest.kt
assertThat(body.contentLength()).isEqualTo(3) assertThat(bodyToHex(body)).isEqualTo("616263") assertThat(bodyToHex(body), "Retransmit body").isEqualTo("616263") } @Test fun byteArrayRange() { val contentType = "text/plain".toMediaType() val body: RequestBody = ".abcd".toByteArray().toRequestBody(contentType, 1, 3) assertThat(body.contentType()).isEqualTo(contentType)
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 16.4K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/ResponseBodyJvmTest.kt
class ResponseBodyJvmTest { @Test fun stringEmpty() { val body = body("") assertThat(body.string()).isEqualTo("") } @Test fun stringLooksLikeBomButTooShort() { val body = body("000048") assertThat(body.string()).isEqualTo("\u0000\u0000H") } @Test fun stringDefaultsToUtf8() { val body = body("68656c6c6f") assertThat(body.string()).isEqualTo("hello") } @Test
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 13K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/ResponseBody.kt
* closes its response body. If you invoke [Call.execute] or implement [Callback.onResponse] you * must close this body by calling any of the following methods: * * * `Response.close()` * * `Response.body().close()` * * `Response.body().source().close()` * * `Response.body().charStream().close()` * * `Response.body().byteStream().close()` * * `Response.body().bytes()` * * `Response.body().string()` *
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 10.7K bytes - Viewed (0) -
docs/recipes.md
Download a file, print its headers, and print its response body as a string. The `string()` method on response body is convenient and efficient for small documents. But if the response body is large (greater than 1 MiB), avoid `string()` because it will load the entire document into memory. In that case, prefer to process the body as a stream. === ":material-language-kotlin: Kotlin" ```kotlin
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) -
okhttp/src/test/java/okhttp3/RequestCommonTest.kt
assertThat(request.body).isNull() assertThat(request.tags).isEmpty() } @Test fun constructorNoMethod() { val url = "https://example.com/".toHttpUrl() val body = "hello".toRequestBody() val headers = headersOf("User-Agent", "RequestTest") val request = Request( url = url, headers = headers, body = body, )
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 10.7K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/DuplexTest.kt
requestBody2.writeUtf8("request body\n") requestBody2.close() val responseBody2 = response2.body.source() assertThat(responseBody2.readUtf8Line()) .isEqualTo("response body") assertTrue(responseBody2.exhausted()) body.awaitSuccess() // No more requests attempted! (call.request().body as AsyncRequestBody?)!!.assertNoMoreSinks() }
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Sat Jan 20 10:30:28 GMT 2024 - 23.9K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/Request.kt
open fun head(): Builder = commonHead() open fun post(body: RequestBody): Builder = commonPost(body) @JvmOverloads open fun delete(body: RequestBody? = commonEmptyRequestBody): Builder = commonDelete(body) open fun put(body: RequestBody): Builder = commonPut(body) open fun patch(body: RequestBody): Builder = commonPatch(body) open fun method( method: String,
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Sat Apr 06 04:17:44 GMT 2024 - 10.5K bytes - Viewed (0) -
src/main/java/org/codelibs/fess/app/web/api/admin/searchlist/ApiAdminSearchlistAction.java
validateApi(body, messages -> {}); if (StringUtil.isBlank(body.q)) { // query matches on all documents. body.q = Constants.MATCHES_ALL_QUERY; } final SearchRenderData renderData = new SearchRenderData(); body.initialize(); try { searchHelper.search(body, renderData, getUserBean());
Java - Registered: Mon May 06 08:04:11 GMT 2024 - Last Modified: Thu Feb 22 01:37:57 GMT 2024 - 10.2K bytes - Viewed (0)