Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 314 for comparator (0.12 sec)

  1. guava/src/com/google/common/collect/ComparatorOrdering.java

        this.comparator = checkNotNull(comparator);
      }
    
      @Override
      public int compare(@ParametricNullness T a, @ParametricNullness T b) {
        return comparator.compare(a, b);
      }
    
      @Override
      public boolean equals(@CheckForNull Object object) {
        if (object == this) {
          return true;
        }
        if (object instanceof ComparatorOrdering) {
          ComparatorOrdering<?> that = (ComparatorOrdering<?>) object;
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sun Jun 20 14:22:42 UTC 2021
    - 1.9K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/collect/SortedLists.java

              Comparator<? super E> comparator,
              @ParametricNullness E key,
              List<? extends E> list,
              int foundIndex) {
            return FIRST_PRESENT.resultIndex(comparator, key, list, foundIndex) - 1;
          }
        };
    
        abstract <E extends @Nullable Object> int resultIndex(
            Comparator<? super E> comparator,
            @ParametricNullness E key,
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 00:05:46 UTC 2024
    - 11K bytes
    - Viewed (0)
  3. android/guava-tests/benchmark/com/google/common/primitives/UnsignedBytesBenchmark.java

    import java.util.Arrays;
    import java.util.Comparator;
    import java.util.Random;
    
    /**
     * Microbenchmark for {@link UnsignedBytes}.
     *
     * @author Hiroshi Yamauchi
     */
    public class UnsignedBytesBenchmark {
    
      private byte[] ba1;
      private byte[] ba2;
      private byte[] ba3;
      private byte[] ba4;
      private Comparator<byte[]> javaImpl;
      private Comparator<byte[]> unsafeImpl;
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Dec 04 17:37:03 UTC 2017
    - 2.8K bytes
    - Viewed (0)
  4. android/guava-tests/test/com/google/common/collect/ComparatorsTest.java

    /**
     * Tests for {@code Comparators}.
     *
     * @author Louis Wasserman
     */
    @GwtCompatible
    @ElementTypesAreNonnullByDefault
    public class ComparatorsTest extends TestCase {
      public void testLexicographical() {
        Comparator<String> comparator = Ordering.natural();
        Comparator<Iterable<String>> lexy = Comparators.lexicographical(comparator);
    
        ImmutableList<String> empty = ImmutableList.of();
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 6.4K bytes
    - Viewed (0)
  5. guava-gwt/src-super/com/google/common/collect/super/com/google/common/collect/DescendingMultiset.java

      abstract SortedMultiset<E> forwardMultiset();
    
      @Nullable private transient Comparator<? super E> comparator;
    
      @Override
      public Comparator<? super E> comparator() {
        Comparator<? super E> result = comparator;
        if (result == null) {
          return comparator = Ordering.from(forwardMultiset().comparator()).<E>reverse();
        }
        return result;
      }
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Jan 24 16:03:45 UTC 2024
    - 4.2K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/collect/DescendingMultiset.java

      abstract SortedMultiset<E> forwardMultiset();
    
      @LazyInit @CheckForNull private transient Comparator<? super E> comparator;
    
      @Override
      public Comparator<? super E> comparator() {
        Comparator<? super E> result = comparator;
        if (result == null) {
          return comparator = Ordering.from(forwardMultiset().comparator()).<E>reverse();
        }
        return result;
      }
    
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Jun 26 21:02:13 UTC 2023
    - 4.5K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/collect/RegularImmutableTable.java

           * provided but a row Comparator isn't, cellSet() iterates across the rows in the first
           * column, the rows in the second column, etc.
           */
          Comparator<Cell<R, C, V>> comparator =
              (Cell<R, C, V> cell1, Cell<R, C, V> cell2) -> {
                int rowCompare =
                    (rowComparator == null)
                        ? 0
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 7.1K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/collect/Collections2.java

          Iterable<E> elements, Comparator<? super E> comparator) {
        return new OrderedPermutationCollection<E>(elements, comparator);
      }
    
      private static final class OrderedPermutationCollection<E> extends AbstractCollection<List<E>> {
        final ImmutableList<E> inputList;
        final Comparator<? super E> comparator;
        final int size;
    
        OrderedPermutationCollection(Iterable<E> input, Comparator<? super E> comparator) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 18 20:24:49 UTC 2024
    - 22.8K bytes
    - Viewed (0)
  9. guava-gwt/src-super/com/google/common/collect/super/com/google/common/collect/ImmutableSortedSet.java

        private final Comparator<? super E> comparator;
    
        public Builder(Comparator<? super E> comparator) {
          this.comparator = checkNotNull(comparator);
        }
    
        Builder(Comparator<? super E> comparator, int expectedSize) {
          super(expectedSize);
          this.comparator = checkNotNull(comparator);
        }
    
        @CanIgnoreReturnValue
        @Override
        public Builder<E> add(E element) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Aug 19 16:21:24 UTC 2024
    - 15.5K bytes
    - Viewed (0)
  10. guava/src/com/google/common/collect/MinMaxPriorityQueue.java

         */
        private static final int UNSET_EXPECTED_SIZE = -1;
    
        private final Comparator<B> comparator;
        private int expectedSize = UNSET_EXPECTED_SIZE;
        private int maximumSize = Integer.MAX_VALUE;
    
        private Builder(Comparator<B> comparator) {
          this.comparator = checkNotNull(comparator);
        }
    
        /**
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 34.1K bytes
    - Viewed (0)
Back to top