Package org.elasticsearch.search.sort
Class ShardDocSortField
java.lang.Object
org.apache.lucene.search.SortField
org.elasticsearch.search.sort.ShardDocSortField
public class ShardDocSortField
extends org.apache.lucene.search.SortField
A
SortField that first compares the shard index and then uses the document number (_doc)
to tiebreak if the value is the same.-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.lucene.search.SortField
org.apache.lucene.search.SortField.Provider, org.apache.lucene.search.SortField.Type -
Field Summary
FieldsFields inherited from class org.apache.lucene.search.SortField
FIELD_DOC, FIELD_SCORE, missingValue, STRING_FIRST, STRING_LAST -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.apache.lucene.search.FieldComparator<?>getComparator(int numHits, int sortPos)Methods inherited from class org.apache.lucene.search.SortField
equals, getBytesComparator, getCanUsePoints, getComparatorSource, getField, getIndexSorter, getMissingValue, getReverse, getType, hashCode, needsScores, readType, rewrite, setBytesComparator, setCanUsePoints, setMissingValue, toString
-
Field Details
-
NAME
- See Also:
- Constant Field Values
-
-
Constructor Details
-
ShardDocSortField
public ShardDocSortField(int shardRequestIndex, boolean reverse)
-
-
Method Details
-
getComparator
public org.apache.lucene.search.FieldComparator<?> getComparator(int numHits, int sortPos)- Overrides:
getComparatorin classorg.apache.lucene.search.SortField
-