public final class CompletionProposalComparator
extends java.lang.Object
implements java.util.Comparator
Note: this comparator imposes orderings that are inconsistent with equals.
Provisional API: This class/interface is part of an interim API that is still under development and expected to change significantly before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.Constructor and Description |
---|
CompletionProposalComparator()
Creates a comparator that sorts by relevance.
|
Modifier and Type | Method and Description |
---|---|
int |
compare(java.lang.Object o1,
java.lang.Object o2) |
void |
setOrderAlphabetically(boolean orderAlphabetically)
Sets the sort order.
|
public CompletionProposalComparator()
public void setOrderAlphabetically(boolean orderAlphabetically)
false
, i.e. order by
relevance.orderAlphabetically
- true
to order alphabetically,
false
to order by relevancepublic int compare(java.lang.Object o1, java.lang.Object o2)
compare
in interface java.util.Comparator
Copyright (c) IBM Corp. and others 2000, 2010. All Rights Reserved.