lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ilya Zavorin <izavo...@caci.com>
Subject highlighter: how can I get locations of fragments?
Date Tue, 13 Dec 2011 18:40:56 GMT
I know how to get relevant highlighted fragments together with some surrounding text using
Lucene highlighter, namely, using
    	
	Highlighter highlighter = new Highlighter(scorer);
	String[] fragments = highlighter.getBestFragments(stream, fieldContents, fragmentNumber);

But can I instead get pointers to these fragments in the original contents? In other words,
I need to know where these fragments start and, if possible, end.

Thanks,

Ilya Zavorin


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Mime
View raw message