Creates a sort, possibly in reverse, by terms in the given field, parsed to numeric values using a custom {@link FieldCache.Parser}.
subclass an existing numeric parser, or field is null

Namespace: Lucene.Net.Search
Assembly: Lucene.Net (in Lucene.Net.dll) Version: 2.9.4.1

Syntax

C#
public SortField(
	string field,
	Parser parser,
	bool reverse
)
Visual Basic
Public Sub New ( _
	field As String, _
	parser As Parser, _
	reverse As Boolean _
)
Visual C++
public:
SortField(
	String^ field, 
	Parser^ parser, 
	bool reverse
)

Parameters

field
Type: System..::..String
Name of field to sort by. Must not be null.
parser
Type: Lucene.Net.Search..::..Parser
Instance of a {@link FieldCache.Parser}, which must subclass one of the existing numeric parsers from {@link FieldCache}. Sort type is inferred by testing which numeric parser the parser subclasses.
reverse
Type: System..::..Boolean
True if natural order should be reversed.

See Also