Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 12 for writeShort (0.06 sec)

  1. okhttp/src/jvmTest/kotlin/okhttp3/internal/http2/Http2Test.kt

        frame.writeByte(Http2.TYPE_SETTINGS)
        frame.writeByte(FLAG_NONE)
        frame.writeInt(0) // Settings are always on the connection stream 0.
        frame.writeShort(1) // SETTINGS_HEADER_TABLE_SIZE
        frame.writeInt(reducedTableSizeBytes)
        frame.writeShort(2) // SETTINGS_ENABLE_PUSH
        frame.writeInt(0)
        reader.nextFrame(
          requireSettings = false,
          object : BaseTestHandler() {
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Mar 19 19:25:20 UTC 2025
    - 28.1K bytes
    - Viewed (0)
  2. src/main/java/jcifs/smb1/smb1/SmbRandomAccessFile.java

        }
    
        @Override
        public final void writeByte(final int v) throws SmbException {
            tmp[0] = (byte) v;
            write(tmp, 0, 1);
        }
    
        @Override
        public final void writeShort(final int v) throws SmbException {
            Encdec.enc_uint16be((short) v, tmp, 0);
            write(tmp, 0, 2);
        }
    
        @Override
        public final void writeChar(final int v) throws SmbException {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 14.1K bytes
    - Viewed (0)
  3. src/test/java/jcifs/smb/SmbRandomAccessFileTest.java

            doNothing().when(raf).write(any(byte[].class), anyInt(), anyInt());
            doNothing().when(raf).writeShort(anyInt());
    
            raf.writeUTF("é"); // 2-byte UTF-8 char
    
            // size prefix should be 2, and then write called with len=2
            verify(raf).writeShort(eq(2));
            verify(raf).write(any(byte[].class), eq(0), eq(2));
        }
    
        @Test
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 18.1K bytes
    - Viewed (0)
  4. src/main/java/jcifs/smb/SmbRandomAccessFile.java

        }
    
        @Override
        public final void writeByte(final int v) throws SmbException {
            this.tmp[0] = (byte) v;
            write(this.tmp, 0, 1);
        }
    
        @Override
        public final void writeShort(final int v) throws SmbException {
            Encdec.enc_uint16be((short) v, this.tmp, 0);
            write(this.tmp, 0, 2);
        }
    
        @Override
        public final void writeChar(final int v) throws SmbException {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 18.8K bytes
    - Viewed (0)
  5. okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/http2/Http2Writer.kt

            length = settings.size() * 6,
            type = TYPE_SETTINGS,
            flags = FLAG_NONE,
          )
          for (i in 0 until Settings.COUNT) {
            if (!settings.isSet(i)) continue
            sink.writeShort(i)
            sink.writeInt(settings[i])
          }
          sink.flush()
        }
      }
    
      /**
       * Send a connection-level ping to the peer. `ack` indicates this is a reply. The data in
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed May 28 23:28:25 UTC 2025
    - 11K bytes
    - Viewed (0)
  6. src/test/java/jcifs/pac/PacLogonInfoTest.java

            domainSid = new SID("S-1-5-21-1-2-3");
            userSid = new SID("S-1-5-21-1-2-3-1000");
        }
    
        private void writeLittleEndianShort(DataOutputStream dos, short value) throws IOException {
            dos.writeShort(Short.reverseBytes(value));
        }
    
        private void writeLittleEndianInt(DataOutputStream dos, int value) throws IOException {
            dos.writeInt(Integer.reverseBytes(value));
        }
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 12.3K bytes
    - Viewed (0)
  7. guava/src/com/google/common/io/ByteStreams.java

          try {
            output.writeLong(v);
          } catch (IOException impossible) {
            throw new AssertionError(impossible);
          }
        }
    
        @Override
        public void writeShort(int v) {
          try {
            output.writeShort(v);
          } catch (IOException impossible) {
            throw new AssertionError(impossible);
          }
        }
    
        @Override
        public void writeUTF(String s) {
          try {
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Jul 17 15:26:41 UTC 2025
    - 31.1K bytes
    - Viewed (0)
  8. okhttp/src/jvmTest/kotlin/okhttp3/internal/http2/HpackTest.kt

          assertThat(expected.message).isEqualTo("index == 0")
        }
      }
    
      // Example taken from twitter/hpack DecoderTest.testIllegalIndex
      @Test
      fun readIndexedHeaderFieldTooLargeIndex() {
        bytesIn.writeShort(0xff00) // == Indexed - Add idx = 127
        assertFailsWith<IOException> {
          hpackReader!!.readHeaders()
        }.also { expected ->
          assertThat(expected.message).isEqualTo("Header index too large 127")
        }
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Mar 19 19:25:20 UTC 2025
    - 38.6K bytes
    - Viewed (0)
  9. src/main/java/jcifs/smb1/ntlmssp/Type2Message.java

            if (domainLength > 0) {
                writeUShort(targetInfo, offset, 2);
                offset += 2;
                writeUShort(targetInfo, offset, domainLength);
                offset += 2;
                System.arraycopy(domain, 0, targetInfo, offset, domainLength);
                offset += domainLength;
            }
            if (serverLength > 0) {
                writeUShort(targetInfo, offset, 1);
                offset += 2;
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 13K bytes
    - Viewed (0)
  10. src/test/java/jcifs/ntlmssp/NtlmMessageTest.java

        }
    
        @Test
        void testWriteUShort() {
            // Test writeUShort
            byte[] data = new byte[2];
            ByteBuffer expectedBuffer = ByteBuffer.allocate(2).order(ByteOrder.LITTLE_ENDIAN);
    
            // Test with a positive value
            int value = 0x1234;
            NtlmMessage.writeUShort(data, 0, value);
            expectedBuffer.putShort(0, (short) value);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 12.5K bytes
    - Viewed (0)
Back to top