Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 9 of 9 for readUnsignedByte (0.1 sec)

  1. android/guava/src/com/google/common/io/LittleEndianDataInputStream.java

      }
    
      @CanIgnoreReturnValue // to skip a byte
      @Override
      public byte readByte() throws IOException {
        return (byte) readUnsignedByte();
      }
    
      @CanIgnoreReturnValue // to skip a byte
      @Override
      public boolean readBoolean() throws IOException {
        return readUnsignedByte() != 0;
      }
    
      /**
       * Reads a byte from the input stream checking that the end of file (EOF) has not been
       * encountered.
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Wed Feb 12 03:49:18 UTC 2025
    - 7.3K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/io/LittleEndianDataInputStreamTest.java

      }
    
      public void testReadUnsignedByte_eof() throws IOException {
        DataInput in = new LittleEndianDataInputStream(new ByteArrayInputStream(new byte[0]));
        assertThrows(EOFException.class, () -> in.readUnsignedByte());
      }
    
      public void testReadUnsignedShort_eof() throws IOException {
        byte[] buf = {23};
        DataInput in = new LittleEndianDataInputStream(new ByteArrayInputStream(buf));
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Thu Dec 19 18:03:30 UTC 2024
    - 4.9K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/io/ByteArrayDataInput.java

      @Override
      boolean readBoolean();
    
      @CanIgnoreReturnValue // to skip a byte
      @Override
      byte readByte();
    
      @CanIgnoreReturnValue // to skip a byte
      @Override
      int readUnsignedByte();
    
      @CanIgnoreReturnValue // to skip some bytes
      @Override
      short readShort();
    
      @CanIgnoreReturnValue // to skip some bytes
      @Override
      int readUnsignedShort();
    
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Fri Dec 27 20:25:25 UTC 2024
    - 2.7K bytes
    - Viewed (0)
  4. src/test/java/jcifs/smb/SmbRandomAccessFileTest.java

            raf.setLength(0L);
    
            verify(tree, times(1)).send(any(SmbComWrite.class), any(SmbComWriteResponse.class), eq(RequestParam.NO_RETRY));
        }
    
        @Test
        @DisplayName("readBoolean/readByte/readUnsignedByte: decode 1-byte values")
        void read_oneByteVariants() throws Exception {
            SmbRandomAccessFile raf = spy(newInstance("r", false, false, false));
            // For each 1-byte read, fill provided buffer with 0xFF/0x01
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 18.1K bytes
    - Viewed (0)
  5. src/test/java/jcifs/pac/PacDataInputStreamTest.java

        @Test
        public void testReadUnsignedByte() throws IOException {
            byte[] data = new byte[] { (byte) 0xFF };
            PacDataInputStream pdis = createInputStream(data);
            assertEquals(255, pdis.readUnsignedByte());
        }
    
        @Test
        public void testReadUnsignedShort() throws IOException {
            // Little-endian 0xFFFF -> 0xFF 0xFF
            byte[] data = new byte[] { (byte) 0xFF, (byte) 0xFF, 0x00, 0x00 };
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 07:14:38 UTC 2025
    - 9.2K bytes
    - Viewed (0)
  6. src/main/java/jcifs/pac/PacDataInputStream.java

        }
    
        /**
         * Reads an unsigned byte value.
         * @return the unsigned byte value as an integer
         * @throws IOException if an I/O error occurs
         */
        public int readUnsignedByte() throws IOException {
            return readByte() & 0xff;
        }
    
        /**
         * Reads an unsigned 32-bit integer value.
         * @return the unsigned integer value as a long
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 8.9K bytes
    - Viewed (0)
  7. src/main/java/jcifs/smb1/smb1/SmbRandomAccessFile.java

            if (read(tmp, 0, 1) < 0) {
                throw new SmbException("EOF");
            }
            return tmp[0];
        }
    
        @Override
        public final int readUnsignedByte() throws SmbException {
            if (read(tmp, 0, 1) < 0) {
                throw new SmbException("EOF");
            }
            return tmp[0] & 0xFF;
        }
    
        @Override
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 14.1K bytes
    - Viewed (0)
  8. guava/src/com/google/common/io/ByteStreams.java

            throw new IllegalStateException(e);
          } catch (IOException impossible) {
            throw new AssertionError(impossible);
          }
        }
    
        @Override
        public int readUnsignedByte() {
          try {
            return input.readUnsignedByte();
          } catch (IOException e) {
            throw new IllegalStateException(e);
          }
        }
    
        @Override
        public short readShort() {
          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)
  9. src/main/java/jcifs/smb/SmbRandomAccessFile.java

            if (read(this.tmp, 0, 1) < 0) {
                throw new SmbEndOfFileException();
            }
            return this.tmp[0];
        }
    
        @Override
        public final int readUnsignedByte() throws SmbException {
            if (read(this.tmp, 0, 1) < 0) {
                throw new SmbEndOfFileException();
            }
            return this.tmp[0] & 0xFF;
        }
    
        @Override
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 18.8K bytes
    - Viewed (0)
Back to top