C# Class Lucene.Net.Sandbox.Queries.SortedSetSortField

SortField for SortedSetDocValues. A SortedSetDocValues contains multiple values for a field, so sorting with this technique "selects" a value as the representative sort value for the document. By default, the minimum value in the set is selected as the sort value, but this can be customized. Selectors other than the default do have some limitations (see below) to ensure that all selections happen in constant-time for performance. Like sorting by string, this also supports sorting missing values as first or last, via SetMissingValue(object). Limitations: Fields containing int.MaxValue or more unique values are unsupported. Selectors other than the default Selector.MIN require optional codec support. However several codecs provided by Lucene, including the current default codec, support this.
Inheritance: Lucene.Net.Search.SortField
Mostra file Open project: apache/lucenenet Class Usage Examples

Public Methods

Method Description
Equals ( object obj ) : bool
GetComparator ( int numHits, int sortPos ) : FieldComparator
GetHashCode ( ) : int
SortedSetSortField ( string field, bool reverse ) : Lucene.Net.Index

Creates a sort, possibly in reverse, by the minimum value in the set for the document.

SortedSetSortField ( string field, bool reverse, Selector selector ) : Lucene.Net.Index

Creates a sort, possibly in reverse, specifying how the sort value from the document's set is selected.

ToString ( ) : string

Method Details

Equals() public method

public Equals ( object obj ) : bool
obj object
return bool

GetComparator() public method

public GetComparator ( int numHits, int sortPos ) : FieldComparator
numHits int
sortPos int
return Lucene.Net.Search.FieldComparator

GetHashCode() public method

public GetHashCode ( ) : int
return int

SortedSetSortField() public method

Creates a sort, possibly in reverse, by the minimum value in the set for the document.
public SortedSetSortField ( string field, bool reverse ) : Lucene.Net.Index
field string Name of field to sort by. Must not be null.
reverse bool True if natural order should be reversed.
return Lucene.Net.Index

SortedSetSortField() public method

Creates a sort, possibly in reverse, specifying how the sort value from the document's set is selected.
public SortedSetSortField ( string field, bool reverse, Selector selector ) : Lucene.Net.Index
field string Name of field to sort by. Must not be null.
reverse bool True if natural order should be reversed.
selector Selector /// custom selector for choosing the sort value from the set. /// /// NOTE: selectors other than require optional codec support. ///
return Lucene.Net.Index

ToString() public method

public ToString ( ) : string
return string