use of org.apache.lucene.search.highlight.TermVectorLeafReader in project lucene-solr by apache.
the class TermVectorOffsetStrategy method getOffsetsEnums.
@Override
public List<OffsetsEnum> getOffsetsEnums(IndexReader reader, int docId, String content) throws IOException {
Terms tvTerms = reader.getTermVector(docId, field);
if (tvTerms == null) {
return Collections.emptyList();
}
LeafReader leafReader = new TermVectorLeafReader(field, tvTerms);
docId = 0;
return createOffsetsEnumsFromReader(leafReader, docId);
}
Aggregations