lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Yonik Seeley <yo...@lucidimagination.com>
Subject Re: SortField questions
Date Tue, 04 Aug 2009 13:56:38 GMT
On Tue, Aug 4, 2009 at 5:46 AM, Michael
McCandless<lucene@mikemccandless.com> wrote:
> On Mon, Aug 3, 2009 at 10:29 PM, Yonik Seeley<yonik@lucidimagination.com> wrote:
>> Why is "reversed" passed into SortField.getComparator(), and what does it mean?
>> Should it always be passed as sortField.getReversed() (and if so, why
>> does the param exist at all)?
>
> reversed may be passed on to some comparators (currently only
> StringOrdVal and CUSTOM) so that they can possibly optimize when that
> field is the primary sort.

OK, it sounds like it should always be the same as SortField.getReversed() then?
In which case it seems redundant to pass it into
SortField.getComparator() since SortField already keeps track of it?

-Yonik
http://www.lucidimagination.com

---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-dev-help@lucene.apache.org


Mime
View raw message