- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 18 for payload (0.18 sec)
-
okhttp/src/test/java/okhttp3/internal/ws/WebSocketWriterTest.kt
val payload = Buffer() while (payload.completeSegmentByteCount() <= PAYLOAD_BYTE_MAX) { payload.writeByte('0'.code) } serverWriter.writeMessageFrame(OPCODE_BINARY, payload.snapshot()) // Write directly to the unbuffered sink. This ensures it will become single frame. assertData("827e") // 'e' == 4-byte follow-up length. assertData(format("%04X", payload.completeSegmentByteCount()))
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 9.3K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/ws/WebSocketReader.kt
import okhttp3.internal.ws.WebSocketProtocol.OPCODE_FLAG_CONTROL import okhttp3.internal.ws.WebSocketProtocol.OPCODE_TEXT import okhttp3.internal.ws.WebSocketProtocol.PAYLOAD_BYTE_MAX import okhttp3.internal.ws.WebSocketProtocol.PAYLOAD_LONG import okhttp3.internal.ws.WebSocketProtocol.PAYLOAD_SHORT import okhttp3.internal.ws.WebSocketProtocol.toggleMask import okio.Buffer import okio.BufferedSource import okio.ByteString /**
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 9.8K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/http2/MockHttp2Peer.kt
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Thu Apr 11 22:09:35 GMT 2024 - 8.7K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/ws/WebSocketWriter.kt
/** Send a ping with the supplied [payload]. */ @Throws(IOException::class) fun writePing(payload: ByteString) { writeControlFrame(OPCODE_CONTROL_PING, payload) } /** Send a pong with the supplied [payload]. */ @Throws(IOException::class) fun writePong(payload: ByteString) { writeControlFrame(OPCODE_CONTROL_PONG, payload) } /**
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 5.9K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/ws/WebSocketRecorder.kt
} fun assertTextMessage(payload: String?) { assertThat(nextEvent()).isEqualTo(Message(string = payload)) } fun assertBinaryMessage(payload: ByteString?) { assertThat(nextEvent()).isEqualTo(Message(payload)) } fun assertPing(payload: ByteString) { assertThat(nextEvent()).isEqualTo(Ping(payload)) } fun assertPong(payload: ByteString) {
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 6.9K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/ws/WebSocketProtocol.kt
* special values [PAYLOAD_SHORT] or [PAYLOAD_LONG]. */ internal const val PAYLOAD_BYTE_MAX = 125L /** Maximum length of close message in bytes. */ internal const val CLOSE_MESSAGE_MAX = PAYLOAD_BYTE_MAX - 2 /** * Value for [B1_MASK_LENGTH] which indicates the next two bytes are the unsigned length. */ internal const val PAYLOAD_SHORT = 126
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 4.8K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/http2/Http2Test.kt
requireSettings = false, object : BaseTestHandler() { override fun ping( ack: Boolean, payload1: Int, payload2: Int, ) { assertThat(ack).isTrue() assertThat(payload1).isEqualTo(expectedPayload1) assertThat(payload2).isEqualTo(expectedPayload2) } }, ) } @Test fun maxLengthDataFrame() {
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 28.1K bytes - Viewed (0) -
okhttp-tls/src/main/kotlin/okhttp3/tls/internal/der/DerWriter.kt
sink.writeByte(0b1000_0000 or lengthByteCount) for (shift in (lengthByteCount - 1) * 8 downTo 0 step 8) { sink.writeByte((length shr shift).toInt()) } } // Write the payload. sink.writeAll(content) } /** * Execute [block] with a new namespace for type hints. Type hints from the enclosing type are no * longer usable by the current type's members. */
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 5.7K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/ws/WebSocketReaderTest.kt
} @Test fun closeLengthOfOneThrows() { data.write("880100".decodeHex()) // Close with invalid 1-byte payload assertFailsWith<ProtocolException> { clientReader.processNextFrame() }.also { expected -> assertThat(expected.message) .isEqualTo("Malformed close payload length of 1.") } } @Test fun closeCallsCallback() {
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Jan 08 01:13:22 GMT 2024 - 14.4K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/ws/RealWebSocket.kt
} @Synchronized override fun onReadPing(payload: ByteString) { // Don't respond to pings after we've failed or sent the close frame. if (failed || enqueuedClose && messageAndCloseQueue.isEmpty()) return pongQueue.add(payload) runWriter() receivedPingCount++ } @Synchronized override fun onReadPong(payload: ByteString) { // This API doesn't expose pings.
Plain Text - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Mon Apr 01 14:21:25 GMT 2024 - 22.1K bytes - Viewed (0)