- Sort Score
- Result 10 results
- Languages All
Results 3061 - 3070 of 3,109 for Link (0.04 sec)
-
okhttp/src/test/java/okhttp3/MultipartBodyTest.kt
override fun contentType(): MediaType? { return null } @Throws(IOException::class) override fun writeTo(sink: BufferedSink) { sink.writeUtf8(body) } } val expected = """ |--123 | |Quick |--123 | |Brown |--123 | |Fox
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 10.4K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/cache2/RelayTest.kt
val pipe = Pipe(1024) val sink = pipe.sink.buffer() val relay = edit(file, pipe.source, metadata, 5) val future1 = executor.submit(sourceReader(relay.newSource())) val future2 = executor.submit(sourceReader(relay.newSource())) Thread.sleep(500) sink.writeUtf8("abcdefghij") Thread.sleep(500) sink.writeUtf8("klmnopqrst") sink.close() assertThat<ByteString>(future1.get())
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Thu Apr 11 22:09:35 UTC 2024 - 8.1K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/http2/Http2Connection.kt
source: BufferedSource = socket.source().buffer(), sink: BufferedSink = socket.sink().buffer(), ) = apply { this.socket = socket this.connectionName = when { client -> "$okHttpName $peerName" else -> "MockWebServer $peerName" } this.source = source this.sink = sink } fun listener(listener: Listener) = apply {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Apr 20 17:03:43 UTC 2024 - 32.6K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/ResponseJvmTest.kt
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 3.1K bytes - Viewed (0) -
docs/recipes.md
val requestBody = object : RequestBody() { override fun contentType() = MEDIA_TYPE_MARKDOWN override fun writeTo(sink: BufferedSink) { sink.writeUtf8("Numbers\n") sink.writeUtf8("-------\n") for (i in 2..997) { sink.writeUtf8(String.format(" * $i = ${factor(i)}\n")) } } private fun factor(n: Int): String {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Fri Feb 18 08:52:22 UTC 2022 - 40.2K bytes - Viewed (0) -
okhttp-tls/src/main/kotlin/okhttp3/tls/internal/der/DerReader.kt
private class CountingSource(source: Source) : ForwardingSource(source) { var bytesRead = 0L override fun read( sink: Buffer, byteCount: Long, ): Long { val result = delegate.read(sink, byteCount) if (result == -1L) return -1L bytesRead += result return result } }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 10.5K bytes - Viewed (0) -
okhttp-idna-mapping-table/src/main/kotlin/okhttp3/internal/idn/SimpleIdnaMappingTable.kt
when (mapping.type) { TYPE_IGNORED -> Unit TYPE_MAPPED, TYPE_DISALLOWED_STD3_MAPPED -> { sink.write(mapping.mappedTo) } TYPE_DEVIATION, TYPE_DISALLOWED_STD3_VALID, TYPE_VALID -> { sink.writeUtf8CodePoint(codePoint) } TYPE_DISALLOWED -> { sink.writeUtf8CodePoint(codePoint) result = false } } return result } }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 6.8K bytes - Viewed (0) -
guava-tests/test/com/google/common/io/CharSourceTester.java
assertExpectedString(builder.toString()); } public void testCopyTo_charSink() throws IOException { TestCharSink sink = new TestCharSink(); assertEquals(expected.length(), source.copyTo(sink)); assertExpectedString(sink.getString()); } public void testRead_toString() throws IOException { String string = source.read(); assertExpectedString(string); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Jul 23 14:22:54 UTC 2024 - 7.3K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/http/ThreadInterruptTest.kt
.post( object : RequestBody() { override fun contentType() = null override fun writeTo(sink: BufferedSink) { for (i in 0..9) { sink.writeByte(0) sink.flush() sleep(100) } fail("Expected connection to be closed") } }, )
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 4.6K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/cache/DiskLruCache.kt
*/ fun newSink(index: Int): Sink { synchronized(this@DiskLruCache) { check(!done) if (entry.currentEditor != this) { return blackholeSink() } if (!entry.readable) { written!![index] = true } val dirtyFile = entry.dirtyFiles[index] val sink: Sink try { sink = fileSystem.sink(dirtyFile)
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 34.7K bytes - Viewed (0)