lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chris Hostetter <hossman_luc...@fucit.org>
Subject Re: scorer.skipTo() contr
Date Wed, 06 Jun 2007 23:44:01 GMT
: Hi, following LUCENE-912, looking closer at skipTo() in
: DisjunctionMaxScorer, it seems not to follow Scorer.skipTo() "contract":
:
:      "Skips to the first match beyond the current whose document number is
: greater than or equal to a given target."
:
: It is the "__beyond__ the current" requirement that is not satisfied.

skipTo semantics have always made my head hurt, but it may be that the
contract is expressed too simplisticly ... i believe the expectation is
that while skipTo should always "skip to the first match beyond the
current whose document number is greater than or equal to a given target."
there is a unwritten expectation that the "target" will always be greater
then the current s.doc().

I may be wrong about that ... i am afterall speculating about an unwritten
assumption.

The "behaves as if written" clause of the skipTo docs however make it
clear that anytime skipTo is called, the document should be advanced at
least one match no matter what the input is .. and your test seems to
indicate this is also not the case.




-Hoss


---------------------------------------------------------------------
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