HomeSort by relevance Sort by last modified time
    Searched refs:comparator (Results 26 - 50 of 772) sorted by null

12 3 4 5 6 7 8 91011>>

  /packages/apps/TV/tests/common/src/com/android/tv/testing/
ComparatorTester.java 24 import java.util.Comparator;
28 * Tester for {@link Comparator} relationships between groups of T.
33 * {@link Comparator#compare(Object, Object)} == 0 to each other.
53 private final Comparator<T> comparator; field in class:ComparatorTester
56 public static <T> ComparatorTester<T> withoutEqualsTest(Comparator<T> comparator) {
57 return new ComparatorTester<>(comparator);
60 private ComparatorTester(Comparator<T> comparator) {
    [all...]
  /external/jacoco/org.jacoco.report/src/org/jacoco/report/internal/html/table/
SortIndex.java 16 import java.util.Comparator;
20 * A index on a list of items sorted with a given {@link Comparator}. The index
28 private final Comparator<? super T> comparator; field in class:SortIndex
42 return comparator.compare(item, o.item);
52 * Creates a new index based in the given comparator.
54 * @param comparator
55 * comparator to sort items
57 public SortIndex(final Comparator<? super T> comparator) {
    [all...]
  /external/guava/guava-gwt/src/com/google/common/collect/
EmptyImmutableSortedSet_CustomFieldSerializer.java 23 import java.util.Comparator;
43 Comparator<Object> comparator = (Comparator<Object>) reader.readObject(); local
52 ImmutableSortedSet.orderedBy(comparator).build();
57 writer.writeObject(instance.comparator());
ImmutableSortedMap_CustomFieldSerializerBase.java 24 import java.util.Comparator;
42 Comparator<Object> comparator = (Comparator<Object>) reader.readObject(); local
44 SortedMap<Object, Object> entries = new TreeMap<Object, Object>(comparator);
47 return ImmutableSortedMap.orderedBy(comparator).putAll(entries).build();
52 writer.writeObject(instance.comparator());
  /external/guava/guava-gwt/src-super/com/google/common/collect/super/com/google/common/collect/
ImmutableSortedAsList.java 19 import java.util.Comparator;
41 @Override public Comparator<? super E> comparator() { method in class:ImmutableSortedAsList
42 return delegateCollection().comparator();
AbstractSortedMultiset.java 21 import java.util.Comparator;
38 @GwtTransient final Comparator<? super E> comparator; field in class:AbstractSortedMultiset
43 this((Comparator) Ordering.natural());
46 AbstractSortedMultiset(Comparator<? super E> comparator) {
47 this.comparator = checkNotNull(comparator);
61 public Comparator<? super E> comparator() { method in class:AbstractSortedMultiset
    [all...]
  /external/junit/src/org/junit/internal/requests/
SortingRequest.java 3 import java.util.Comparator;
12 private final Comparator<Description> fComparator;
14 public SortingRequest(Request request, Comparator<Description> comparator) {
16 fComparator= comparator;
  /external/junit/src/org/junit/runner/manipulation/
Sorter.java 3 import java.util.Comparator;
9 * to use a <code>Sorter</code> directly. Instead, use {@link org.junit.runner.Request#sortWith(Comparator)}.
13 public class Sorter implements Comparator<Description> {
17 public static Sorter NULL= new Sorter(new Comparator<Description>() {
21 private final Comparator<Description> fComparator;
24 * Creates a <code>Sorter</code> that uses <code>comparator</code>
26 * @param comparator the {@link Comparator} to use when sorting tests
28 public Sorter(Comparator<Description> comparator) {
    [all...]
  /libcore/ojluni/src/main/java/java/util/
SortedSet.java 31 * ordering}, or by a {@link Comparator} typically provided at sorted
38 * interface (or be accepted by the specified comparator). Furthermore, all
40 * (or <tt>comparator.compare(e1, e2)</tt>) must not throw a
47 * explicit comparator is provided) must be <i>consistent with equals</i> if
49 * the <tt>Comparable</tt> interface or <tt>Comparator</tt> interface for a
63 * single argument of type <tt>Comparator</tt>, which creates an empty
64 * sorted set sorted according to the specified comparator. 3) A
103 * @see Comparator
110 * Returns the comparator used to order the elements in this set,
114 * @return the comparator used to order the elements in this set
118 Comparator<? super E> comparator(); method in interface:SortedSet
    [all...]
PriorityQueue.java 33 * {@linkplain Comparable natural ordering}, or by a {@link Comparator}
92 * priority queue is ordered by comparator, or by the elements'
93 * natural ordering, if comparator is null: For each node n in the
105 * The comparator, or null if priority queue uses elements'
108 private final Comparator<? super E> comparator; field in class:PriorityQueue
140 * whose elements are ordered according to the specified comparator.
142 * @param comparator the comparator that will be used to order this
147 public PriorityQueue(Comparator<? super E> comparator)
748 public Comparator<? super E> comparator() { method in class:PriorityQueue
    [all...]
  /external/guava/guava-tests/benchmark/com/google/common/collect/
MinMaxPriorityQueueBenchmark.java 28 import java.util.Comparator;
39 @Param private ComparatorType comparator; field in class:MinMaxPriorityQueueBenchmark
42 // NotApplicableException in the expensive comparator case.
52 queue = heap.create(comparator.get());
82 public InvertedMinMaxPriorityQueue(Comparator<T> comparator) {
83 mmHeap = MinMaxPriorityQueue.orderedBy(comparator).create();
100 @Override public Queue<Integer> create(Comparator<Integer> comparator) {
101 return MinMaxPriorityQueue.orderedBy(comparator).create()
    [all...]
  /external/guava/guava/src/com/google/common/collect/
ImmutableSortedMap.java 27 import java.util.Comparator;
65 private static final Comparator<Comparable> NATURAL_ORDER = Ordering.natural();
70 static <K, V> ImmutableSortedMap<K, V> emptyMap(Comparator<? super K> comparator) {
71 if (Ordering.natural().equals(comparator)) {
74 return new EmptyImmutableSortedMap<K, V>(comparator);
79 Comparator<? super K> comparator,
83 return emptyMap(comparator);
95 new RegularImmutableSortedSet<K>(keyBuilder.build(), comparator),
239 Comparator<? super K> comparator = map.comparator(); local
355 private final Comparator<? super K> comparator; field in class:ImmutableSortedMap.Builder
458 public Comparator<? super K> comparator() { method in class:ImmutableSortedMap
680 private final Comparator<Object> comparator; field in class:ImmutableSortedMap.SerializedForm
    [all...]
SortedIterable.java 19 import java.util.Comparator;
23 * An {@code Iterable} whose elements are sorted relative to a {@code Comparator}, typically
31 * Returns the {@code Comparator} by which the elements of this iterable are ordered, or {@code
34 Comparator<? super T> comparator(); method in interface:SortedIterable
38 * nondecreasing order according to the associated {@link #comparator}.
EmptyImmutableSortedMap.java 22 import java.util.Comparator;
36 EmptyImmutableSortedMap(Comparator<? super K> comparator) {
37 this.keySet = ImmutableSortedSet.emptySet(comparator);
41 Comparator<? super K> comparator, ImmutableSortedMap<K, V> descendingMap) {
43 this.keySet = ImmutableSortedSet.emptySet(comparator);
110 return new EmptyImmutableSortedMap<K, V>(Ordering.from(comparator()).reverse(), this);
ImmutableSortedMultiset.java 27 import java.util.Comparator;
33 * are ordered by an explicit comparator, while others follow the natural sort ordering of their
51 * are equivalent. Instead, with an explicit comparator, the following relation determines whether
56 * {(x, y) | comparator.compare(x, y) == 0}}</pre>
86 private static final Comparator<Comparable> NATURAL_ORDER = Ordering.natural();
185 * comparator, call {@link #copyOfSorted} instead. This method iterates over {@code elements} at
232 * Comparator}.
234 * @throws NullPointerException if {@code comparator} or any of {@code elements} is null
237 Comparator<? super E> comparator, Iterator<? extends E> elements)
321 public final Comparator<? super E> comparator() { method in class:ImmutableSortedMultiset
543 Comparator<? super E> comparator; field in class:ImmutableSortedMultiset.SerializedForm
    [all...]
SortedLists.java 24 import java.util.Comparator;
34 * <i>lesser</i> are considered to refer to the comparator on the elements, and the terms
56 Comparator<? super E> comparator, E key, List<? extends E> list, int foundIndex) {
66 Comparator<? super E> comparator, E key, List<? extends E> list, int foundIndex) {
74 int c = comparator.compare(list.get(middle), key);
90 Comparator<? super E> comparator, E key, List<? extends E> list, int foundIndex) {
99 int c = comparator.compare(list.get(middle), key)
    [all...]
AbstractSortedMultiset.java 21 import java.util.Comparator;
38 @GwtTransient final Comparator<? super E> comparator; field in class:AbstractSortedMultiset
43 this((Comparator) Ordering.natural());
46 AbstractSortedMultiset(Comparator<? super E> comparator) {
47 this.comparator = checkNotNull(comparator);
61 public Comparator<? super E> comparator() { method in class:AbstractSortedMultiset
    [all...]
ForwardingSortedMap.java 24 import java.util.Comparator;
44 * comparator of the map to test equality for both keys and values, unlike
66 public Comparator<? super K> comparator() { method in class:ForwardingSortedMap
67 return delegate().comparator();
113 Comparator<? super K> comparator = comparator(); local
114 if (comparator == null) {
117 return ((Comparator<Object>) comparator).compare(k1, k2)
    [all...]
ForwardingSortedSet.java 22 import java.util.Comparator;
43 * comparator (or the natural ordering of the elements, if there is no
44 * comparator) to test element equality. As a result, if the comparator is not
66 public Comparator<? super E> comparator() { method in class:ForwardingSortedSet
67 return delegate().comparator();
98 Comparator<? super E> comparator = comparator(); local
    [all...]
TreeMultiset.java 33 import java.util.Comparator;
42 * or an explicit {@link Comparator}. In all cases, this implementation uses
43 * {@link Comparable#compareTo} or {@link Comparator#compare} instead of {@link Object#equals} to
78 * Creates a new, empty multiset, sorted according to the specified comparator. All elements
79 * inserted into the multiset must be <i>mutually comparable</i> by the specified comparator:
80 * {@code comparator.compare(e1,
85 * @param comparator
86 * the comparator that will be used to sort this multiset. A null value indicates that
90 public static <E> TreeMultiset<E> create(@Nullable Comparator<? super E> comparator) {
    [all...]
  /cts/tests/tests/content/src/android/content/pm/cts/
PackageItemInfo_DisplayNameComparatorTest.java 35 DisplayNameComparator comparator = new DisplayNameComparator(pm); local
44 assertTrue(comparator.compare(pkgItemInfo, cmpInfo) < 0);
45 assertTrue(comparator.compare(pkgItemInfo, pkgItemInfo) == 0);
46 assertTrue(comparator.compare(cmpInfo, pkgItemInfo) > 0);
  /bionic/libc/bionic/
scandir.cpp 72 void Sort(int (*comparator)(const dirent**, const dirent**)) {
73 // If we have entries and a comparator, sort them.
74 if (size_ > 0 && comparator != nullptr) {
76 reinterpret_cast<int (*)(const void*, const void*)>(comparator));
98 int (*comparator)(const dirent**, const dirent**)) {
124 names.Sort(comparator);
134 int (*comparator)(const dirent**, const dirent**)) {
135 return scandirat(AT_FDCWD, dir_path, name_list, filter, comparator);
  /external/replicaisland/src/com/replica/replicaisland/
FixedSizeArray.java 20 import java.util.Comparator;
36 private Comparator<T> mComparator;
51 public FixedSizeArray(int size, Comparator<T> comparator) {
56 mComparator = comparator;
79 * Otherwise, the comparator set on this array (if any) will be used to find the object.
185 * binary search will be performed. If a comparator has been specified with setComparator(),
186 * it will be used to perform the search. If not, the default comparator for the object type
189 * performed. Otherwise, the comparator set on this array (if any) will be used to find the
198 final Comparator comparator = mComparator
    [all...]
  /external/smali/util/src/main/java/org/jf/util/
ArraySortedSet.java 40 @Nonnull private final Comparator<? super T> comparator; field in class:ArraySortedSet
43 private ArraySortedSet(@Nonnull Comparator<? super T> comparator, @Nonnull T[] arr) {
44 // we assume arr is already sorted by comparator, and all entries are unique
45 this.comparator = comparator;
49 public static <T> ArraySortedSet<T> of(@Nonnull Comparator<? super T> comparator, @Nonnull T[] arr) {
50 return new ArraySortedSet<T>(comparator, arr)
131 public Comparator<? super T> comparator() { method in class:ArraySortedSet
    [all...]
CollectionUtils.java 75 public static <T> int compareAsIterable(@Nonnull Comparator<? super T> comparator,
86 int res = comparator.compare(element1, element2);
114 public static <T> int compareAsList(@Nonnull Comparator<? super T> elementComparator,
128 public static <T> Comparator<Collection<? extends T>> listComparator(
129 @Nonnull final Comparator<? super T> elementComparator) {
130 return new Comparator<Collection<? extends T>>() {
141 Comparator<?> comparator = sortedSet.comparator();
    [all...]

Completed in 1169 milliseconds

12 3 4 5 6 7 8 91011>>