Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 121 for Vints (0.24 sec)

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

      public void testIteratorMinAndMax() {
        List<Integer> ints = Lists.newArrayList(5, 3, 0, 9);
        assertEquals(9, (int) numberOrdering.max(ints.iterator()));
        assertEquals(0, (int) numberOrdering.min(ints.iterator()));
    
        // when the values are the same, the first argument should be returned
        Integer a = new Integer(4);
        Integer b = new Integer(4);
        ints = Lists.newArrayList(a, b, b);
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu Mar 07 18:34:03 GMT 2024
    - 42.5K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/collect/OrderingTest.java

      public void testIteratorMinAndMax() {
        List<Integer> ints = Lists.newArrayList(5, 3, 0, 9);
        assertEquals(9, (int) numberOrdering.max(ints.iterator()));
        assertEquals(0, (int) numberOrdering.min(ints.iterator()));
    
        // when the values are the same, the first argument should be returned
        Integer a = new Integer(4);
        Integer b = new Integer(4);
        ints = Lists.newArrayList(a, b, b);
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Mar 07 18:34:03 GMT 2024
    - 42.5K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/primitives/UnsignedIntsTest.java

      }
    
      public void testToLong() {
        for (long a : UNSIGNED_INTS) {
          assertThat(UnsignedInts.toLong((int) a)).isEqualTo(a);
        }
      }
    
      public void testCompare() {
        for (long a : UNSIGNED_INTS) {
          for (long b : UNSIGNED_INTS) {
            int cmpAsLongs = Longs.compare(a, b);
            int cmpAsUInt = UnsignedInts.compare((int) a, (int) b);
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Tue Feb 06 16:10:08 GMT 2024
    - 12.7K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/collect/RegularImmutableSortedMultiset.java

    import com.google.common.annotations.GwtIncompatible;
    import com.google.common.annotations.J2ktIncompatible;
    import com.google.common.annotations.VisibleForTesting;
    import com.google.common.primitives.Ints;
    import java.util.Comparator;
    import javax.annotation.CheckForNull;
    
    /**
     * An immutable sorted multiset with one or more distinct elements.
     *
     * @author Louis Wasserman
     */
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 4.3K bytes
    - Viewed (0)
  5. android/guava-testlib/src/com/google/common/collect/testing/TestIntegerSetGenerator.java

    import com.google.common.collect.testing.SampleElements.Ints;
    import java.util.List;
    import java.util.Set;
    
    /**
     * Create integer sets for collection tests.
     *
     * @author Gregory Kick
     */
    @GwtCompatible
    @ElementTypesAreNonnullByDefault
    public abstract class TestIntegerSetGenerator implements TestSetGenerator<Integer> {
      @Override
      public SampleElements<Integer> samples() {
        return new Ints();
      }
    
      @Override
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Feb 21 16:49:06 GMT 2024
    - 2.1K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/math/IntMath.java

        return Ints.saturatedCast((long) a + b);
      }
    
      /**
       * Returns the difference of {@code a} and {@code b} unless it would overflow or underflow in
       * which case {@code Integer.MAX_VALUE} or {@code Integer.MIN_VALUE} is returned, respectively.
       *
       * @since 20.0
       */
      public static int saturatedSubtract(int a, int b) {
        return Ints.saturatedCast((long) a - b);
      }
    
      /**
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Feb 07 17:50:39 GMT 2024
    - 23.5K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/collect/RegularImmutableMultiset.java

    import com.google.common.annotations.GwtIncompatible;
    import com.google.common.annotations.J2ktIncompatible;
    import com.google.common.collect.Multiset.Entry;
    import com.google.common.primitives.Ints;
    import com.google.errorprone.annotations.concurrent.LazyInit;
    import com.google.j2objc.annotations.WeakOuter;
    import java.io.Serializable;
    import javax.annotation.CheckForNull;
    
    /**
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Nov 30 21:54:06 GMT 2023
    - 4.1K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/math/Quantiles.java

        for (int i = 0; i < len; i++) {
          doubles[i] = longs[i];
        }
        return doubles;
      }
    
      private static double[] intsToDoubles(int[] ints) {
        int len = ints.length;
        double[] doubles = new double[len];
        for (int i = 0; i < len; i++) {
          doubles[i] = ints[i];
        }
        return doubles;
      }
    
      /**
       * Performs an in-place selection to find the element which would appear at a given index in a
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri May 12 17:02:53 GMT 2023
    - 29.9K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/hash/BloomFilterTest.java

        BloomFilter<byte[]> bf = BloomFilter.create(Funnels.byteArrayFunnel(), 100);
        for (int i = 0; i < 10; i++) {
          bf.put(Ints.toByteArray(i));
        }
    
        BloomFilter<byte[]> copy = SerializableTester.reserialize(bf);
        for (int i = 0; i < 10; i++) {
          assertTrue(copy.mightContain(Ints.toByteArray(i)));
        }
        assertEquals(bf.expectedFpp(), copy.expectedFpp());
    
        SerializableTester.reserializeAndAssert(bf);
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Nov 09 22:49:56 GMT 2023
    - 21.3K bytes
    - Viewed (0)
  10. guava-testlib/src/com/google/common/collect/testing/SampleElements.java

        public Enums() {
          // elements aren't sorted, to better test SortedSet iteration ordering
          super(AnEnum.B, AnEnum.A, AnEnum.C, AnEnum.D, AnEnum.E);
        }
      }
    
      public static class Ints extends SampleElements<Integer> {
        public Ints() {
          // elements aren't sorted, to better test SortedSet iteration ordering
          super(1, 0, 2, 3, 4);
        }
      }
    
      public static <K extends @Nullable Object, V extends @Nullable Object>
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Feb 21 16:49:06 GMT 2024
    - 4.1K bytes
    - Viewed (0)
Back to top