public class ToParentBlockJoinSortField extends SortField
SortField.Type| Modifier and Type | Field and Description |
|---|---|
private BitSetProducer |
childFilter |
private boolean |
order |
private BitSetProducer |
parentFilter |
FIELD_DOC, FIELD_SCORE, missingValue, STRING_FIRST, STRING_LAST| Constructor and Description |
|---|
ToParentBlockJoinSortField(java.lang.String field,
SortField.Type type,
boolean reverse,
BitSetProducer parentFilter,
BitSetProducer childFilter)
Create ToParentBlockJoinSortField.
|
ToParentBlockJoinSortField(java.lang.String field,
SortField.Type type,
boolean reverse,
boolean order,
BitSetProducer parentFilter,
BitSetProducer childFilter)
Create ToParentBlockJoinSortField.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object obj)
Returns true if
o is equal to this. |
FieldComparator<?> |
getComparator(int numHits,
int sortPos)
Returns the
FieldComparator to use for
sorting. |
private FieldComparator<?> |
getDoubleComparator(int numHits) |
private FieldComparator<?> |
getFloatComparator(int numHits) |
private FieldComparator<?> |
getIntComparator(int numHits) |
private FieldComparator<?> |
getLongComparator(int numHits) |
private FieldComparator<?> |
getStringComparator(int numHits) |
int |
hashCode()
Returns a hash code for this
SortField instance. |
getBytesComparator, getComparatorSource, getField, getMissingValue, getReverse, getType, needsScores, rewrite, setBytesComparator, setMissingValue, toStringprivate final boolean order
private final BitSetProducer parentFilter
private final BitSetProducer childFilter
public ToParentBlockJoinSortField(java.lang.String field,
SortField.Type type,
boolean reverse,
BitSetProducer parentFilter,
BitSetProducer childFilter)
field - The sort field on the nested / child level.type - The sort type on the nested / child level.reverse - Whether natural order should be reversed on the nested / child level.parentFilter - Filter that identifies the parent documents.childFilter - Filter that defines which child documents participates in sorting.public ToParentBlockJoinSortField(java.lang.String field,
SortField.Type type,
boolean reverse,
boolean order,
BitSetProducer parentFilter,
BitSetProducer childFilter)
field - The sort field on the nested / child level.type - The sort type on the nested / child level.reverse - Whether natural order should be reversed on the nested / child document level.order - Whether natural order should be reversed on the parent level.parentFilter - Filter that identifies the parent documents.childFilter - Filter that defines which child documents participates in sorting.public FieldComparator<?> getComparator(int numHits, int sortPos)
SortFieldFieldComparator to use for
sorting.getComparator in class SortFieldnumHits - number of top hits the queue will storesortPos - position of this SortField within Sort. The comparator is primary if sortPos==0,
secondary if sortPos==1, etc. Some comparators can
optimize themselves when they are the primary sort.FieldComparator to use when sortingprivate FieldComparator<?> getStringComparator(int numHits)
private FieldComparator<?> getIntComparator(int numHits)
private FieldComparator<?> getLongComparator(int numHits)
private FieldComparator<?> getFloatComparator(int numHits)
private FieldComparator<?> getDoubleComparator(int numHits)
public int hashCode()
SortFieldSortField instance. If a
FieldComparatorSource was provided, it must properly
implement hashCode (unless a singleton is always used).public boolean equals(java.lang.Object obj)
SortFieldo is equal to this. If a
FieldComparatorSource was provided, it must properly
implement equals (unless a singleton is always used).