- Sort Score
- Result 10 results
- Languages All
Results 1 - 8 of 8 for encodedLength (0.05 sec)
-
src/test/java/jcifs/internal/smb2/ioctl/ValidateNegotiateInfoRequestTest.java
byte[] buffer = new byte[request.size()]; int encodedLength = request.encode(buffer, 0); // Verify encoded length matches size assertEquals(request.size(), encodedLength); // Verify capabilities (4 bytes) assertEquals(DEFAULT_CAPABILITIES, SMBUtil.readInt4(buffer, 0));
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 11.7K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/base/Utf8Test.java
// We can't use Character.isSurrogate(c) because of GWT. public void testEncodedLength_validStrings() { assertEquals(0, Utf8.encodedLength("")); assertEquals(11, Utf8.encodedLength("Hello world")); assertEquals(8, Utf8.encodedLength("Résumé")); assertEquals( 461, Utf8.encodedLength( "威廉·莎士比亞(William Shakespeare," + "1564年4月26號—1616年4月23號[1])係隻英國嗰演員、劇作家同詩人,"
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Thu Aug 07 16:05:33 UTC 2025 - 12.8K bytes - Viewed (0) -
okhttp/src/jvmTest/kotlin/okhttp3/internal/http2/HuffmanTest.kt
import assertk.assertThat import assertk.assertions.isEqualTo import java.util.Random import okhttp3.internal.http2.Huffman.decode import okhttp3.internal.http2.Huffman.encode import okhttp3.internal.http2.Huffman.encodedLength import okio.Buffer import okio.ByteString import okio.ByteString.Companion.encodeUtf8 import okio.ByteString.Companion.toByteString import org.junit.jupiter.api.Assertions.assertEquals import org.junit.jupiter.api.Test
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Fri Dec 27 13:39:56 UTC 2024 - 1.8K bytes - Viewed (0) -
okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/http2/Huffman.kt
accumulator = accumulator shl (8 - accumulatorBitCount) accumulator = accumulator or (0xffL ushr accumulatorBitCount) sink.writeByte(accumulator.toInt()) } } fun encodedLength(bytes: ByteString): Int { var bitCount = 0L for (i in 0 until bytes.size) { val byteIn = bytes[i] and 0xff bitCount += CODE_BIT_COUNTS[byteIn].toLong() }
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Wed Mar 19 19:25:20 UTC 2025 - 11K bytes - Viewed (0) -
android/guava/src/com/google/common/base/Utf8.java
* time and space. * * @throws IllegalArgumentException if {@code sequence} contains ill-formed UTF-16 (unpaired * surrogates) */ public static int encodedLength(CharSequence sequence) { // Warning to maintainers: this implementation is highly optimized. int utf16Length = sequence.length(); int utf8Length = utf16Length; int i = 0;
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Mon Aug 11 19:31:30 UTC 2025 - 7K bytes - Viewed (0) -
okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/http2/Hpack.kt
value = value ushr 7 } out.writeByte(value) } @Throws(IOException::class) fun writeByteString(data: ByteString) { if (useCompression && Huffman.encodedLength(data) < data.size) { val huffmanBuffer = Buffer() Huffman.encode(data, huffmanBuffer) val huffmanBytes = huffmanBuffer.readByteString()
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Mon May 05 16:01:00 UTC 2025 - 22.4K bytes - Viewed (0) -
src/test/java/jcifs/internal/CommonServerMessageBlockTest.java
// Given byte[] buffer = new byte[512]; int encodeIndex = 0; int decodeIndex = 0; int encodeLength = 100; int decodeLength = 100; when(messageBlock.encode(buffer, encodeIndex)).thenReturn(encodeLength); when(messageBlock.decode(buffer, decodeIndex)).thenReturn(decodeLength); // When
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 15.7K bytes - Viewed (0) -
src/test/java/jcifs/internal/smb1/trans/SmbComTransactionTest.java
// Initialize transaction buffer to avoid NPE transaction.setBuffer(new byte[SmbComTransaction.TRANSACTION_BUF_SIZE]); // Test encode int encodeLength = transaction.encode(buffer, 0); assertTrue(encodeLength > 0); // Test decode - should not throw exception assertDoesNotThrow(() -> { transaction.decode(buffer, 0); }); } @Test
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 10.7K bytes - Viewed (0)