Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 11 for hasRemaining (0.22 sec)

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

        requireNonNull(seq); // safe because of checkOpen
        return hasRemaining() ? seq.charAt(pos++) : -1;
      }
    
      @Override
      public synchronized int read(char[] cbuf, int off, int len) throws IOException {
        checkPositionIndexes(off, off + len, cbuf.length);
        checkOpen();
        requireNonNull(seq); // safe because of checkOpen
        if (!hasRemaining()) {
          return -1;
        }
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Feb 28 20:13:02 GMT 2023
    - 4.5K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/hash/AbstractNonStreamingHashFunctionTest.java

            }
    
            @Override
            protected void process(ByteBuffer bb) {
              while (bb.hasRemaining()) {
                out.write(bb.get());
              }
            }
    
            @Override
            protected void processRemaining(ByteBuffer bb) {
              while (bb.hasRemaining()) {
                out.write(bb.get());
              }
            }
          };
        }
      }
    
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 4.4K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/hash/AbstractNonStreamingHashFunctionTest.java

            }
    
            @Override
            protected void process(ByteBuffer bb) {
              while (bb.hasRemaining()) {
                out.write(bb.get());
              }
            }
    
            @Override
            protected void processRemaining(ByteBuffer bb) {
              while (bb.hasRemaining()) {
                out.write(bb.get());
              }
            }
          };
        }
      }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 4.4K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/hash/FunnelsTest.java

              protected HashCode makeHash() {
                throw new UnsupportedOperationException();
              }
    
              @Override
              protected void process(ByteBuffer bb) {
                while (bb.hasRemaining()) {
                  bb.get();
                }
              }
            };
        try {
          funnel.funnel(null, primitiveSink);
          fail();
        } catch (NullPointerException ok) {
        }
      }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri Oct 02 16:24:50 GMT 2020
    - 5.9K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/hash/FunnelsTest.java

              protected HashCode makeHash() {
                throw new UnsupportedOperationException();
              }
    
              @Override
              protected void process(ByteBuffer bb) {
                while (bb.hasRemaining()) {
                  bb.get();
                }
              }
            };
        try {
          funnel.funnel(null, primitiveSink);
          fail();
        } catch (NullPointerException ok) {
        }
      }
    
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Fri Oct 02 16:24:50 GMT 2020
    - 5.9K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/hash/SipHashFunction.java

          b += CHUNK_SIZE;
          processM(buffer.getLong());
        }
    
        @Override
        protected void processRemaining(ByteBuffer buffer) {
          b += buffer.remaining();
          for (int i = 0; buffer.hasRemaining(); i += 8) {
            finalM ^= (buffer.get() & 0xFFL) << i;
          }
        }
    
        @Override
        protected HashCode makeHash() {
          // End with a byte encoding the positive integer b mod 256.
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Apr 20 18:43:59 GMT 2021
    - 5.3K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/hash/Murmur3_32HashFunction.java

          ByteOrder bo = buffer.order();
          buffer.order(ByteOrder.LITTLE_ENDIAN);
          while (buffer.remaining() >= 4) {
            putInt(buffer.getInt());
          }
          while (buffer.hasRemaining()) {
            putByte(buffer.get());
          }
          buffer.order(bo);
          return this;
        }
    
        @CanIgnoreReturnValue
        @Override
        public Hasher putInt(int i) {
          update(4, i);
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Jun 15 20:59:00 GMT 2022
    - 11.9K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/hash/Crc32cHashFunction.java

          if (finished) {
            return;
          }
          crc0 = combine(0, crc0);
          crc0 = combine(crc0, crc1);
          crc0 = combine(crc0, crc2);
          crc0 = combine(crc0, crc3);
          while (bb.hasRemaining()) {
            crc0 = (crc0 >>> 8) ^ BYTE_TABLE[(bb.get() ^ crc0) & 0xFF];
          }
          finished = true;
        }
    
        @Override
        protected HashCode makeHash() {
          if (!finished) {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Apr 20 18:43:59 GMT 2021
    - 21.3K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/hash/HashTestUtils.java

        byte[] bytes = new byte[rng.nextInt(256) + 1];
        rng.nextBytes(bytes);
        ByteBuffer buffer = ByteBuffer.wrap(bytes);
        HashCode unused = hashFunction.hashBytes(buffer);
        assertFalse(buffer.hasRemaining());
      }
    
      static void assertHashByteBufferPreservesByteOrder(HashFunction hashFunction) {
        Random rng = new Random(0L);
        byte[] bytes = new byte[rng.nextInt(256) + 1];
        rng.nextBytes(bytes);
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Oct 10 19:45:10 GMT 2022
    - 25.3K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/io/ByteStreams.java

          return position - oldPosition;
        }
    
        ByteBuffer buf = ByteBuffer.wrap(createBuffer());
        long total = 0;
        while (from.read(buf) != -1) {
          Java8Compatibility.flip(buf);
          while (buf.hasRemaining()) {
            total += to.write(buf);
          }
          Java8Compatibility.clear(buf);
        }
        return total;
      }
    
      /** Max array length on JVM. */
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Jan 17 18:59:58 GMT 2024
    - 29.7K bytes
    - Viewed (0)
Back to top