- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 67 for writeUtf8 (0.56 sec)
-
samples/guide/src/main/java/okhttp3/recipes/PostStreaming.java
return MEDIA_TYPE_MARKDOWN; } @Override public void writeTo(BufferedSink sink) throws IOException { sink.writeUtf8("Numbers\n"); sink.writeUtf8("-------\n"); for (int i = 2; i <= 997; i++) { sink.writeUtf8(String.format(" * %s = %s\n", i, factor(i))); } } private String factor(int n) { for (int i = 2; i < n; i++) {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Fri Jul 06 03:18:15 UTC 2018 - 2.1K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/cache/DiskLruCache.kt
entry.readable = true writeUtf8(CLEAN).writeByte(' '.code) writeUtf8(entry.key) entry.writeLengths(this) writeByte('\n'.code) if (success) { entry.sequenceNumber = nextSequenceNumber++ } } else { lruEntries.remove(entry.key) writeUtf8(REMOVE).writeByte(' '.code) writeUtf8(entry.key) writeByte('\n'.code) }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 34.7K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/url/-Url.kt
// Skip this character. } else if (codePoint == ' '.code && encodeSet === FORM_ENCODE_SET) { // Encode ' ' as '+'. writeUtf8("+") } else if (codePoint == '+'.code && plusIsSpace) { // Encode '+' as '%2B' since we permit ' ' to be encoded as either '+' or '%20'. writeUtf8(if (alreadyEncoded) "+" else "%2B") } else if (codePoint < 0x20 || codePoint == 0x7f || codePoint >= 0x80 && !unicodeAllowed ||
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Tue Jan 09 12:33:05 UTC 2024 - 7.3K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/http2/Http2ConnectionTest.kt
val sink1 = stream1.getSink().buffer() val sink2 = stream2.getSink().buffer() sink1.writeUtf8("abc") assertFailsWith<IOException> { sink2.writeUtf8("abc") sink2.flush() }.also { expected -> assertThat(expected.message).isEqualTo("stream was reset: REFUSED_STREAM") } sink1.writeUtf8("def") sink1.close() assertFailsWith<ConnectionShutdownException> {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Apr 20 17:03:43 UTC 2024 - 75.4K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/MultipartReader.kt
Buffer() .writeUtf8("--") .writeUtf8(boundary) .readByteString() /** * This delimiter typically precedes all subsequent parts. It may also precede the first part * if the body contains a preamble. */ private val crlfDashDashBoundary = Buffer() .writeUtf8("\r\n--") .writeUtf8(boundary) .readByteString()
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 7.1K bytes - Viewed (0) -
okhttp-tls/src/main/kotlin/okhttp3/tls/internal/der/DerWriter.kt
sink.write(bitString.byteString) } fun writeOctetString(byteString: ByteString) { sink().write(byteString) } fun writeUtf8(value: String) { sink().writeUtf8(value) } fun writeObjectIdentifier(s: String) { val utf8 = Buffer().writeUtf8(s) val v1 = utf8.readDecimalLong() require(utf8.readByte() == '.'.code.toByte()) val v2 = utf8.readDecimalLong()
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 5.7K bytes - Viewed (0) -
mockwebserver-deprecated/src/main/kotlin/okhttp3/mockwebserver/MockResponse.kt
bytesOut.writeUtf8("\r\n") bytesOut.write(body, chunkSize) bytesOut.writeUtf8("\r\n") } bytesOut.writeUtf8("0\r\n") // Last chunk. Trailers follow! this.body = bytesOut } fun setChunkedBody( body: String, maxChunkSize: Int, ): MockResponse = setChunkedBody(Buffer().writeUtf8(body), maxChunkSize) @JvmName("-deprecated_getHeaders")
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/PostStreamingWithPipe.java
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Fri Jul 06 03:18:15 UTC 2018 - 3.1K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/ResponseBodyJvmTest.kt
return null } override fun contentLength(): Long { return 5 } override fun source(): BufferedSource { val source = Buffer().writeUtf8("hello") return object : ForwardingSource(source) { @Throws(IOException::class) override fun close() { closed.set(true) super.close() }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon May 13 13:42:37 UTC 2024 - 13K bytes - Viewed (0) -
okhttp-tls/src/main/kotlin/okhttp3/tls/internal/der/Adapters.kt
override fun decode(reader: DerReader): String = reader.readUtf8String() override fun encode( writer: DerWriter, value: String, ) = writer.writeUtf8(value) }, ) /** * Permits alphanumerics, spaces, and these: * * ``` * ' () + , - . / : = ? * ``` *
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 15K bytes - Viewed (0)