Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 160 for Kasper (0.17 sec)

  1. android/guava/src/com/google/common/hash/Hasher.java

     */
    @Beta
    @ElementTypesAreNonnullByDefault
    public interface Hasher extends PrimitiveSink {
      @CanIgnoreReturnValue
      @Override
      Hasher putByte(byte b);
    
      @CanIgnoreReturnValue
      @Override
      Hasher putBytes(byte[] bytes);
    
      @CanIgnoreReturnValue
      @Override
      Hasher putBytes(byte[] bytes, int off, int len);
    
      @CanIgnoreReturnValue
      @Override
      Hasher putBytes(ByteBuffer bytes);
    
      @CanIgnoreReturnValue
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Jun 15 20:59:00 GMT 2022
    - 5.5K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/hash/FarmHashFingerprint64Test.java

        assertEquals(hashCode, hasher.hash().asLong());
    
        hasher = HASH_FN.newHasher();
        hasher.putBytes(new byte[] {0x01, 0x01, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00});
        assertEquals(hashCode, hasher.hash().asLong());
    
        hasher = HASH_FN.newHasher();
        hasher.putLong(0x0000000001000101L);
        assertEquals(hashCode, hasher.hash().asLong());
    
        hasher = HASH_FN.newHasher();
        hasher
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Jun 26 15:56:47 GMT 2017
    - 6.2K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/hash/MacHashFunctionTest.java

      public void testPutAfterHash() {
        Hasher hasher = Hashing.hmacMd5(MD5_KEY).newHasher();
    
        assertEquals(
            "9753980fe94daa8ecaa82216519393a9",
            hasher.putString("The quick brown fox jumps over the lazy dog", UTF_8).hash().toString());
        assertThrows(IllegalStateException.class, () -> hasher.putInt(42));
      }
    
      public void testHashTwice() {
        Hasher hasher = Hashing.hmacMd5(MD5_KEY).newHasher();
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 13.8K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/hash/MessageDigestHashFunction.java

        try {
          return MessageDigest.getInstance(algorithmName);
        } catch (NoSuchAlgorithmException e) {
          throw new AssertionError(e);
        }
      }
    
      @Override
      public Hasher newHasher() {
        if (supportsClone) {
          try {
            return new MessageDigestHasher((MessageDigest) prototype.clone(), bytes);
          } catch (CloneNotSupportedException e) {
            // falls through
          }
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed May 25 20:32:46 GMT 2022
    - 5K bytes
    - Viewed (0)
  5. guava-gwt/src-super/com/google/common/collect/super/com/google/common/collect/ForwardingImmutableSet.java

        return delegate.toArray(other);
      }
    
      @Override
      public String toString() {
        return delegate.toString();
      }
    
      // TODO(cpovirk): equals(), as well, in case it's any faster than Sets.equalsImpl?
    
      @Override
      public int hashCode() {
        return delegate.hashCode();
      }
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Jan 23 18:43:40 GMT 2024
    - 2.2K bytes
    - Viewed (0)
  6. guava-tests/benchmark/com/google/common/hash/HashFunctionBenchmark.java

      @Param HashFunctionEnum hashFunctionEnum;
    
      private byte[] testBytes;
    
      @BeforeExperiment
      void setUp() {
        testBytes = new byte[size];
        random.nextBytes(testBytes);
      }
    
      @Benchmark
      int hasher(int reps) {
        HashFunction hashFunction = hashFunctionEnum.getHashFunction();
        int result = 37;
        for (int i = 0; i < reps; i++) {
          result ^= hashFunction.newHasher().putBytes(testBytes).hash().asBytes()[0];
        }
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 2.3K bytes
    - Viewed (0)
  7. guava-tests/benchmark/com/google/common/hash/MessageDigestAlgorithmBenchmark.java

        HASH_FUNCTION_DIRECT() {
          @Override
          public byte[] hash(Algorithm algorithm, byte[] input) {
            return algorithm.getHashFunction().hashBytes(input).asBytes();
          }
        },
        HASH_FUNCTION_VIA_HASHER() {
          @Override
          public byte[] hash(Algorithm algorithm, byte[] input) {
            return algorithm.getHashFunction().newHasher().putBytes(input).hash().asBytes();
          }
        };
        ;
    
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 3.5K bytes
    - Viewed (0)
  8. guava/src/com/google/common/base/Predicate.java

     * Otherwise, at least reduce <i>explicit</i> dependencies on this type by using lambda expressions
     * or method references instead of classes, leaving your code easier to migrate in the future.
     *
     * <p>The {@link Predicates} class provides common predicates and related utilities.
     *
     * <p>See the Guava User Guide article on <a
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 15 16:12:13 GMT 2024
    - 3.5K bytes
    - Viewed (0)
  9. guava/src/com/google/common/base/Throwables.java

        return stringWriter.toString();
      }
    
      /**
       * Returns the stack trace of {@code throwable}, possibly providing slower iteration over the full
       * trace but faster iteration over parts of the trace. Here, "slower" and "faster" are defined in
       * comparison to the normal way to access the stack trace, {@link Throwable#getStackTrace()
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Wed Mar 06 15:38:58 GMT 2024
    - 20.6K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/base/Throwables.java

        return stringWriter.toString();
      }
    
      /**
       * Returns the stack trace of {@code throwable}, possibly providing slower iteration over the full
       * trace but faster iteration over parts of the trace. Here, "slower" and "faster" are defined in
       * comparison to the normal way to access the stack trace, {@link Throwable#getStackTrace()
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Mar 06 15:38:58 GMT 2024
    - 20.6K bytes
    - Viewed (0)
Back to top