}
private PrefixUncompressedBytes anyMatchingTerm = new PrefixUncompressedBytes();
@Override
public Bytes findAnyMatching(long docId, Bytes prefix) {
Bytes term;
if (prefix.getLength() == 0) {
term = subQueryNode.findAnyMatching(docId, prefix);
} else {
Bytes min = compress(prefix);
byte[] prefixBytes = prefix.getBytes();
Util.incrementBinary(prefixBytes);
Bytes max = compress(new ArrayBytes(prefixBytes));
Range r = new Range(ArrayBytes.EMPTY_BYTES, ArrayBytes.EMPTY_BYTES, ArrayBytes.EMPTY_BYTES, true, true);
r.setBoundsAndExtractPrefix(min, max);
term = subQueryNode.findAnyMatching(docId, r.getPrefix());
}
if (term == null) return null;