List of usage examples for org.apache.lucene.search PhrasePositions nextPosition
final boolean nextPosition() throws IOException
position as location - offset, so that a matching exact phrase is easily identified when all PhrasePositions have exactly the same position. From source file:org.opengrok.suggest.query.customized.CustomSloppyPhraseScorer.java
License:Apache License
/** advance a PhrasePosition and update 'end', return false if exhausted */ private boolean advancePP(PhrasePositions pp) throws IOException { if (!pp.nextPosition()) { return false; }//from w w w . j av a 2 s.c o m if (pp.position > end) { end = pp.position; } return true; }