- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 37 for readUtf8 (0.24 sec)
-
okhttp/src/test/java/okhttp3/internal/cache2/RelayTest.kt
val source1 = relay.newSource()!!.buffer() val source2 = relay.newSource()!!.buffer() assertThat(source1.readUtf8(5)).isEqualTo("abcde") assertThat(source2.readUtf8(5)).isEqualTo("abcde") assertThat(source2.readUtf8(5)).isEqualTo("fghij") assertThat(source1.readUtf8(5)).isEqualTo("fghij") assertThat(source1.exhausted()).isTrue() assertThat(source2.exhausted()).isTrue() source1.close()
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Thu Apr 11 22:09:35 UTC 2024 - 8.1K bytes - Viewed (0) -
mockwebserver-deprecated/src/main/kotlin/okhttp3/mockwebserver/RecordedRequest.kt
val handshake: Handshake? val requestUrl: HttpUrl? @get:JvmName("-deprecated_utf8Body") @Deprecated( message = "Use body.readUtf8()", replaceWith = ReplaceWith("body.readUtf8()"), level = DeprecationLevel.ERROR, ) val utf8Body: String get() = body.readUtf8() val tlsVersion: TlsVersion? get() = handshake?.tlsVersion internal constructor( requestLine: String,
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 4.1K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/cache2/FileOperatorTest.kt
operatorA.write(36, bufferA, 33) operatorB.read(0, bufferB, 9) assertThat(bufferB.readUtf8()).isEqualTo("Dodgson!\n") operatorA.read(9, bufferA, 27) assertThat(bufferA.readUtf8()).isEqualTo("You shouldn't use my name.\n") operatorB.read(36, bufferB, 33) assertThat(bufferB.readUtf8()).isEqualTo("Dodgson, we've got Dodgson here!\n") } @Test fun largeRead() {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 5.8K bytes - Viewed (0) -
src/main/java/org/codelibs/fess/util/UpgradeUtil.java
final String filePath = indexConfigPath + "/" + indexName + "/" + path; try { final String source = FileUtil.readUTF8(filePath); try (CurlResponse response = ComponentUtil.getCurlHelper().post("/_configsync/file").param("path", path).body(source).execute()) { if (response.getHttpStatusCode() == 200) {
Registered: Thu Oct 31 13:40:30 UTC 2024 - Last Modified: Thu Feb 22 01:37:57 UTC 2024 - 9.1K bytes - Viewed (0) -
container-tests/src/test/java/okhttp3/containers/BasicProxyTest.kt
testRequest { val url = URI(mockServer.endpoint + "/person?name=peter").toURL() val connection = url.openConnection() as HttpURLConnection assertThat(connection.inputStream.source().buffer().readUtf8()).contains("Peter the person") } } @Test fun testUrlConnectionPlaintextProxied() { testRequest { val proxy = Proxy( Proxy.Type.HTTP,
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Fri Apr 05 03:30:42 UTC 2024 - 5.9K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/CacheCorruptionTest.kt
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Jan 20 10:30:28 UTC 2024 - 6K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/FormBodyTest.kt
body.writeTo(out) assertThat(out.readUtf8()).isEqualTo(expected) } @Test fun encodedPair() { val body = FormBody.Builder() .add("sim", "ple") .build() val expected = "sim=ple" assertThat(body.contentLength()).isEqualTo(expected.length.toLong()) val buffer = Buffer() body.writeTo(buffer) assertThat(buffer.readUtf8()).isEqualTo(expected) } @Test
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 7.8K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/http/HttpHeaders.kt
if (i == -1L) return null // Unterminated quoted string. if (this[i] == '"'.code.toByte()) { result.write(this, i) // Consume '"'. readByte() return result.readUtf8() } if (size == i + 1L) return null // Dangling escape. result.write(this, i) // Consume '\'. readByte() result.write(this, 1L) // The escaped character. } } /**
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 7.2K bytes - Viewed (0) -
samples/guide/src/main/java/okhttp3/recipes/kt/PostPath.kt
if (!response.isSuccessful) throw IOException("Unexpected code $response") fileSystem.sink(path).use { response.body.source().readAll(it) } println(fileSystem.source(path).buffer().readUtf8()) } } companion object { val MEDIA_TYPE_JSON = "application/json".toMediaType() } } fun main() { PostPath().run()
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 1.6K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/RequestBodyTest.kt
fun testFileDescriptorRead() { assertOnFileDescriptor(content = "Hello") { fd -> val requestBody = fd.toRequestBody() val buffer = Buffer() requestBody.writeTo(buffer) assertThat(buffer.readUtf8()).isEqualTo("Hello") } } @Test fun testFileDescriptorDefaultMediaType() { assertOnFileDescriptor { fd -> val requestBody = fd.toRequestBody()
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 3.6K bytes - Viewed (0)