You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by yi...@indiana.edu on 2005/05/05 01:36:34 UTC
highlight problem
Hi, All,
I use lucene highlight package to generate KWIC for our application.
The part of the code is as following:
=====================================================
if(text != null ){
TokenStream tokenStream = analyzer.tokenStream("contents",
new StringReader(text));
// Get 3 best fragments and seperate with a "..."
result = highlighter.getBestFragments(tokenStream,
text, 3, "...");
}
=====================================================
However, I got a very strange problem. One of my search results from our
records contains far too much of the text of the paper. It doesn't happen
for the same paper when I changed the search criteria.
Thanks very mcuh for your help,
Ying
---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org