Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 324 for Hashing (0.1 sec)

  1. guava-tests/test/com/google/common/collect/HashingTest.java

     * limitations under the License.
     */
    
    package com.google.common.collect;
    
    import static com.google.common.collect.Hashing.smear;
    
    import com.google.common.annotations.GwtCompatible;
    import junit.framework.TestCase;
    
    /** Tests for {@code Hashing}. */
    @GwtCompatible
    @ElementTypesAreNonnullByDefault
    public class HashingTest extends TestCase {
      public void testSmear() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Feb 19 20:34:55 UTC 2024
    - 5.9K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/collect/HashingTest.java

     * limitations under the License.
     */
    
    package com.google.common.collect;
    
    import static com.google.common.collect.Hashing.smear;
    
    import com.google.common.annotations.GwtCompatible;
    import junit.framework.TestCase;
    
    /** Tests for {@code Hashing}. */
    @GwtCompatible
    @ElementTypesAreNonnullByDefault
    public class HashingTest extends TestCase {
      public void testSmear() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Feb 19 20:34:55 UTC 2024
    - 5.9K bytes
    - Viewed (0)
  3. android/guava-tests/benchmark/com/google/common/hash/HashFunctionBenchmark.java

     *
     * <p>Parameters for the benchmark are:
     *
     * <ul>
     *   <li>size: The length of the byte array to hash.
     *   <li>hashFunctionEnum: The {@link HashFunction} to use for hashing.
     * </ul>
     *
     * @author Kurt Alfred Kluever
     */
    public class HashFunctionBenchmark {
    
      // Use a statically configured random instance for all of the benchmarks
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Dec 04 17:37:03 UTC 2017
    - 2.3K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/hash/HashCodeTest.java

      }
    
      public void testHashCode_equalsAndSerializable() throws Exception {
        sanityTester().testEqualsAndSerializable();
      }
    
      public void testRoundTripHashCodeUsingBaseEncoding() {
        HashCode hash1 = Hashing.sha1().hashString("foo", US_ASCII);
        HashCode hash2 = HashCode.fromBytes(BaseEncoding.base16().lowerCase().decode(hash1.toString()));
        assertEquals(hash1, hash2);
      }
    
      public void testObjectHashCode() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Oct 21 14:28:19 UTC 2024
    - 13.1K bytes
    - Viewed (0)
  5. guava/src/com/google/common/collect/RegularImmutableMap.java

         * of non-null entries.
         */
        @SuppressWarnings("nullness")
        Entry<K, V>[] entries =
            (n == entryArray.length) ? (Entry<K, V>[]) entryArray : createEntryArray(n);
        int tableSize = Hashing.closedTableSize(n, MAX_LOAD_FACTOR);
        @Nullable ImmutableMapEntry<K, V>[] table = createEntryArray(tableSize);
        int mask = tableSize - 1;
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue May 28 18:11:09 UTC 2024
    - 16.2K bytes
    - Viewed (0)
  6. android/guava-tests/test/com/google/common/hash/HashCodeTest.java

      }
    
      public void testHashCode_equalsAndSerializable() throws Exception {
        sanityTester().testEqualsAndSerializable();
      }
    
      public void testRoundTripHashCodeUsingBaseEncoding() {
        HashCode hash1 = Hashing.sha1().hashString("foo", US_ASCII);
        HashCode hash2 = HashCode.fromBytes(BaseEncoding.base16().lowerCase().decode(hash1.toString()));
        assertEquals(hash1, hash2);
      }
    
      public void testObjectHashCode() {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Oct 21 14:28:19 UTC 2024
    - 13.1K bytes
    - Viewed (0)
  7. guava/src/com/google/common/hash/Murmur3_128HashFunction.java

      static final HashFunction MURMUR3_128 = new Murmur3_128HashFunction(0);
    
      static final HashFunction GOOD_FAST_HASH_128 =
          new Murmur3_128HashFunction(Hashing.GOOD_FAST_HASH_SEED);
    
      // TODO(user): when the shortcuts are implemented, update BloomFilterStrategies
      private final int seed;
    
      Murmur3_128HashFunction(int seed) {
        this.seed = seed;
      }
    
      @Override
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue Apr 20 18:43:59 UTC 2021
    - 5.6K bytes
    - Viewed (0)
  8. android/guava-tests/benchmark/com/google/common/hash/HashStringBenchmark.java

    import static java.nio.charset.StandardCharsets.UTF_8;
    
    import com.google.caliper.BeforeExperiment;
    import com.google.caliper.Benchmark;
    import com.google.caliper.Param;
    import java.util.Random;
    
    /** Benchmarks for the hashing of UTF-8 strings. */
    public class HashStringBenchmark {
      static class MaxCodePoint {
        final int value;
    
        /**
         * Convert the input string to a code point. Accepts regular decimal numerals, hex strings, and
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 00:26:48 UTC 2024
    - 5.2K bytes
    - Viewed (0)
  9. guava-tests/benchmark/com/google/common/hash/HashStringBenchmark.java

    import static java.nio.charset.StandardCharsets.UTF_8;
    
    import com.google.caliper.BeforeExperiment;
    import com.google.caliper.Benchmark;
    import com.google.caliper.Param;
    import java.util.Random;
    
    /** Benchmarks for the hashing of UTF-8 strings. */
    public class HashStringBenchmark {
      static class MaxCodePoint {
        final int value;
    
        /**
         * Convert the input string to a code point. Accepts regular decimal numerals, hex strings, and
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 00:26:48 UTC 2024
    - 5.2K bytes
    - Viewed (0)
  10. cmd/erasure-metadata-utils_test.go

    	}
    
    	// Tests hashing order to be consistent.
    	for i, testCase := range testCases {
    		hashedOrder := hashOrder(testCase.objectName, 16)
    		if !reflect.DeepEqual(testCase.hashedOrder, hashedOrder) {
    			t.Errorf("Test case %d: Expected \"%v\" but failed \"%v\"", i+1, testCase.hashedOrder, hashedOrder)
    		}
    	}
    
    	// Tests hashing order to fail for when order is '-1'.
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Jan 18 07:03:17 UTC 2024
    - 7.4K bytes
    - Viewed (0)
Back to top