- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 33 for readByteString (0.17 sec)
-
okhttp-tls/src/main/kotlin/okhttp3/tls/internal/der/DerReader.kt
val byteString = source.readByteString(bytesLeft) return BitString(byteString, unusedBitCount) } fun readOctetString(): ByteString { if (bytesLeft == -1L || constructed) { throw ProtocolException("constructed octet strings not supported for DER") } return source.readByteString(bytesLeft) } fun readUtf8String(): String {
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/src/test/java/okhttp3/internal/cache2/FileOperatorTest.kt
write(data) val operator = FileOperator( randomAccessFile!!.getChannel(), ) val buffer = Buffer() operator.read(0, buffer, data.size.toLong()) assertThat(buffer.readByteString()).isEqualTo(data) } @Test fun largeWrite() { val data = randomByteString(1000000) val operator = FileOperator( randomAccessFile!!.getChannel(), )
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 5.8K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/http2/Http2Reader.kt
throw IOException("Required SETTINGS preface not received") } } else { // The server reads the CONNECTION_PREFACE byte string. val connectionPreface = source.readByteString(CONNECTION_PREFACE.size.toLong()) if (logger.isLoggable(FINE)) logger.fine(format("<< CONNECTION ${connectionPreface.hex()}")) if (CONNECTION_PREFACE != connectionPreface) {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 19.9K bytes - Viewed (0) -
okhttp-testing-support/src/main/kotlin/okhttp3/UppercaseResponseInterceptor.kt
sink: Buffer, byteCount: Long, ): Long { val buffer = Buffer() val read = delegate.read(buffer, byteCount) if (read != -1L) { sink.write(buffer.readByteString().toAsciiUppercase()) } return read } } }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 1.8K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/http2/HuffmanTest.kt
assertThat(encodedLength(data).toLong()).isEqualTo(encodeBuffer.size) val decodeBuffer = Buffer() decode(encodeBuffer, encodeBuffer.size, decodeBuffer) assertEquals(data, decodeBuffer.readByteString()) }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Thu Jan 04 05:32:07 UTC 2024 - 1.8K bytes - Viewed (0) -
okhttp-testing-support/src/main/kotlin/okhttp3/UppercaseRequestInterceptor.kt
return object : ForwardingSink(sink) { @Throws(IOException::class) override fun write( source: Buffer, byteCount: Long, ) { val bytes = source.readByteString(byteCount) delegate.write( Buffer() .write(bytes.toAsciiUppercase()), byteCount, ) } } }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 1.9K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/MultipartReader.kt
.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() private var partCount = 0 private var closed = false
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-hpacktests/src/test/java/okhttp3/internal/http2/HpackRoundTripTest.kt
) val newCases = mutableListOf<Case>() for (case in story.cases) { hpackWriter.writeHeaders(case.headersList) newCases += case.copy(wire = bytesOut.readByteString()) } testDecoder(story.copy(cases = newCases)) } companion object { private val RAW_DATA = arrayOf("raw-data") }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 2K bytes - Viewed (0) -
docs/features/events.md
// Consume and discard the response body. response.body().source().readByteString(); } System.out.println("REQUEST 2 (pooled connection)"); try (Response response = client.newCall(request).execute()) { // Consume and discard the response body. response.body().source().readByteString(); } ``` And the listener prints the corresponding events: ``` REQUEST 1 (new connection)
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sun Feb 06 02:19:09 UTC 2022 - 7.7K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/ws/WebSocketWriter.kt
validateCloseCode(code) } payload = Buffer().run { writeShort(code) if (reason != null) { write(reason) } readByteString() } } try { writeControlFrame(OPCODE_CONTROL_CLOSE, payload) } finally { writerClosed = true } } @Throws(IOException::class)
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 5.9K bytes - Viewed (0)