Dear Carsten, your question was about the purpose of the offset-Attribute and the reader.getTermFreqVector method. You have asked because this method is not very fast.
imho main reason for TermFreqVectors is highlighting. (FastVectorHighlighter and DefaultSolrHighlighter#doHighlightingByHighlighter) You normally use highlighting only on a small part of the hit list. If you have a fast analyser you do not need TermFreqVector because you can calculate the offset on the fly. ( Calculate from the value of a stored field. Sometimes TermFreqVector can be used as substitute of a stored field. ) Best regards Karsten in Context: http://lucene.472066.n3.nabble.com/Offsets-in-3-6-4-0-td3994830.html#a3995288 --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org For additional commands, e-mail: java-user-h...@lucene.apache.org