If you use PostingsHighlighter, then Passage.getMatchStarts/Ends gives you the offsets of each match. You'd need a custom PassageFormatter that takes these ints and saves them somewhere; or possibly the patch on LUCENE-4906 (allowing you to return custom objects, not just String) from your highlighter.
I'm less familiar with the older highlighters but likely it's possible to get the absolute offsets from them as well. Mike McCandless http://blog.mikemccandless.com On Mon, Aug 12, 2013 at 1:20 PM, Lingviston <vladislav.ermo...@outlook.com> wrote: > I think that's OK for me. I just need to know the right way to get them. > Notice that queries must support boolean operators, *, ? and qoutes. > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/How-to-get-hits-coordinates-in-Lucene-4-4-0-tp4083913p4084046.html > Sent from the Lucene - Java Users mailing list archive at Nabble.com. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org > For additional commands, e-mail: java-user-h...@lucene.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org For additional commands, e-mail: java-user-h...@lucene.apache.org