You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by Dmitry Serebrennikov <dm...@earthlink.net> on 2001/10/11 03:29:35 UTC
skipTo()
Greetings,
Doesn't this implementation of skipTo(int target) fail when the TermDocs
is already set on the target?
I got this one out of SegmentsTermDocs in SegmentsReader.java, but I
think there are many copies of this code in other places.
======================
public boolean skipTo(int target) throws IOException {
do {
if (!next())
return false;
} while (target > doc());
return true;
}
======================