- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 96 for contentType (0.12 sec)
-
okhttp/src/commonJvmAndroid/kotlin/okhttp3/ResponseBody.kt
val buffer = Buffer().writeString(this, charset) return buffer.asResponseBody(finalContentType, buffer.size) } /** Returns a new response body that transmits this byte array. */ @JvmStatic @JvmName("create") fun ByteArray.toResponseBody(contentType: MediaType? = null): ResponseBody = Buffer() .write(this)
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Tue May 27 14:51:25 UTC 2025 - 11.6K bytes - Viewed (0) -
okhttp/src/jvmTest/kotlin/okhttp3/RequestTest.kt
val contentType = "text/plain; charset=utf-16be".toMediaType() val body = "\u0800".toRequestBody(contentType) assertThat(body.contentType()).isEqualTo(contentType) assertThat(body.contentLength()).isEqualTo(2) assertThat(bodyToHex(body)).isEqualTo("0800") } @Test fun byteArray() { val contentType = "text/plain".toMediaType() val body: RequestBody = "abc".toByteArray().toRequestBody(contentType)
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Sat Aug 16 09:39:51 UTC 2025 - 19K bytes - Viewed (0) -
okhttp-logging-interceptor/src/main/kotlin/okhttp3/logging/HttpLoggingInterceptor.kt
!contentEncoding.equals("gzip", ignoreCase = true) } private fun bodyIsStreaming(response: Response): Boolean { val contentType = response.body.contentType() return contentType != null && contentType.type == "text" && contentType.subtype == "event-stream" } companion object
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Thu Aug 21 14:27:04 UTC 2025 - 11.4K bytes - Viewed (0) -
okhttp/src/commonJvmAndroid/kotlin/okhttp3/MultipartBody.kt
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Wed Mar 19 19:25:20 UTC 2025 - 10.9K bytes - Viewed (0) -
okhttp/src/jvmTest/kotlin/okhttp3/MultipartBodyTest.kt
.Builder("123") .addPart("Hello, World!".toRequestBody(null)) .build() 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)
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Wed Mar 19 19:25:20 UTC 2025 - 10.5K bytes - Viewed (0) -
okhttp/src/jvmTest/kotlin/okhttp3/ResponseBodyJvmTest.kt
} @Test fun stringClosesUnderlyingSource() { val closed = AtomicBoolean() val body: ResponseBody = object : ResponseBody() { override fun contentType(): MediaType? = null override fun contentLength(): Long = 5 override fun source(): BufferedSource { val source = Buffer().writeUtf8("hello")
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Wed Mar 19 19:25:20 UTC 2025 - 12.4K bytes - Viewed (0) -
fess-crawler/src/test/java/org/codelibs/fess/crawler/client/storage/StorageClientTest.java
Registered: Sun Sep 21 03:50:09 UTC 2025 - Last Modified: Thu Aug 07 02:55:08 UTC 2025 - 13.8K bytes - Viewed (0) -
fess-crawler/src/main/java/org/codelibs/fess/crawler/extractor/impl/TikaExtractor.java
if (StringUtil.isNotEmpty(resourceName)) { metadata.set(ExtractData.RESOURCE_NAME_KEY, resourceName); } if (StringUtil.isNotBlank(contentType)) { metadata.set(ExtractData.CONTENT_TYPE, contentType); } if (StringUtil.isNotBlank(contentEncoding)) { metadata.set(ExtractData.CONTENT_ENCODING, contentEncoding); } if (pdfPassword != null) {
Registered: Sun Sep 21 03:50:09 UTC 2025 - Last Modified: Thu Aug 07 02:55:08 UTC 2025 - 30.7K bytes - Viewed (0) -
src/main/java/org/codelibs/fess/mylasta/direction/sponsor/FessMultipartRequestHandler.java
return new JakartaServletDiskFileUpload(fileItemFactory) { @Override public byte[] getBoundary(final String contentType) { // for security final byte[] boundary = super.getBoundary(contentType); checkBoundarySize(contentType, boundary); return boundary; } }; }
Registered: Thu Sep 04 12:52:25 UTC 2025 - Last Modified: Sat Mar 15 06:53:53 UTC 2025 - 18.6K bytes - Viewed (0) -
src/test/java/org/codelibs/fess/it/CrawlTestBase.java
protected static Response deleteMethod(final String path) { return given().contentType("application/json").header("Authorization", getTestToken()).delete(path); } protected static void deleteDocuments(final String queryString) { List<String> docIds = new ArrayList<>(); Response response = given().contentType("application/json") .param("scroll", "1m")
Registered: Thu Sep 04 12:52:25 UTC 2025 - Last Modified: Thu Aug 07 03:06:29 UTC 2025 - 10K bytes - Viewed (0)