Method from org.apache.lucene.index.MultipleTermPositions Detail: |
public final void close() throws IOException {
while (_termPositionsQueue.size() > 0)
_termPositionsQueue.pop().close();
}
|
public final int doc() {
return _doc;
}
|
public final int freq() {
return _freq;
}
|
public byte[] getPayload(byte[] data,
int offset) throws IOException {
throw new UnsupportedOperationException();
}
|
public int getPayloadLength() {
throw new UnsupportedOperationException();
}
|
public boolean isPayloadAvailable() {
return false;
}
|
public final boolean next() throws IOException {
if (_termPositionsQueue.size() == 0)
return false;
_posList.clear();
_doc = _termPositionsQueue.peek().doc();
TermPositions tp;
do {
tp = _termPositionsQueue.peek();
for (int i = 0; i < tp.freq(); i++)
_posList.add(tp.nextPosition());
if (tp.next())
_termPositionsQueue.updateTop();
else {
_termPositionsQueue.pop();
tp.close();
}
} while (_termPositionsQueue.size() > 0 && _termPositionsQueue.peek().doc() == _doc);
_posList.sort();
_freq = _posList.size();
return true;
}
|
public final int nextPosition() {
return _posList.next();
}
|
public int read(int[] arg0,
int[] arg1) throws IOException {
throw new UnsupportedOperationException();
}
|
public void seek(Term arg0) throws IOException {
throw new UnsupportedOperationException();
}
|
public void seek(TermEnum termEnum) throws IOException {
throw new UnsupportedOperationException();
}
|
public final boolean skipTo(int target) throws IOException {
while (_termPositionsQueue.peek() != null && target > _termPositionsQueue.peek().doc()) {
TermPositions tp = _termPositionsQueue.pop();
if (tp.skipTo(target))
_termPositionsQueue.add(tp);
else
tp.close();
}
return next();
}
|