Return-Path: Delivered-To: apmail-jakarta-lucene-user-archive@apache.org Received: (qmail 96623 invoked from network); 12 May 2003 18:59:11 -0000 Received: from exchange.sun.com (192.18.33.10) by daedalus.apache.org with SMTP; 12 May 2003 18:59:11 -0000 Received: (qmail 13482 invoked by uid 97); 12 May 2003 19:01:19 -0000 Delivered-To: qmlist-jakarta-archive-lucene-user@nagoya.betaversion.org Received: (qmail 13475 invoked from network); 12 May 2003 19:01:18 -0000 Received: from daedalus.apache.org (HELO apache.org) (208.185.179.12) by nagoya.betaversion.org with SMTP; 12 May 2003 19:01:18 -0000 Received: (qmail 96174 invoked by uid 500); 12 May 2003 18:59:06 -0000 Mailing-List: contact lucene-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Lucene Users List" Reply-To: "Lucene Users List" Delivered-To: mailing list lucene-user@jakarta.apache.org Received: (qmail 96124 invoked from network); 12 May 2003 18:59:06 -0000 Received: from web40112.mail.yahoo.com (66.218.78.46) by daedalus.apache.org with SMTP; 12 May 2003 18:59:06 -0000 Message-ID: <20030512185911.34365.qmail@web40112.mail.yahoo.com> Received: from [163.188.121.119] by web40112.mail.yahoo.com via HTTP; Mon, 12 May 2003 11:59:11 PDT Date: Mon, 12 May 2003 11:59:11 -0700 (PDT) From: Shoba Ramachandran Subject: Re: Highlighting, startOffset, endOffset To: Lucene Users List In-Reply-To: <1BE7364ABAF3A540AADA600B68C2C21977546C@lyon-01.ever-team.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N I'm using this termhighlighter and never got any problem. Could you be elaborate on how you are using it. -Shoba --- Arpad KATONA wrote: > Hello Lucene Users, > > in order to highlighting terms in a text, i try to > use Maik Schreiber's highlighting solution see "Term > Highlighter" on : > http://jakarta.apache.org/lucene/docs/contributions.html > . > It is based on the "startOffset" and "endOffset" > functions of the "org.apache.lucene.analysis.Token" > class, see the short code sample below. > > org.apache.lucene.analysis.Token token; > TokenStream stream = analyzer.tokenStream(new > StringReader(text)); > while ((token = stream.next()) != null) { > int startOffset = token.startOffset(); > int endOffset = token.endOffset(); > ... > } > > The problem is, that these functions "startOffset" > and "endOffset" seem to return always 0, do you see > why? In the mails archive there is only one mail > that treats this thema : > http://nagoya.apache.org/eyebrowse/ReadMsg?listName=lucene-user@jakarta.apache.org&msgId=489630 > From: Tom Dunstan > Subject: Excerpts > Date: Tue, 1 Oct 2002 12:19:29 +0930 > > but the sender seems to have never got an answer to > his mail... > > Thank you im voraus > > Arpad KATONA > a.katona@ever-team.com > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: > lucene-user-unsubscribe@jakarta.apache.org > For additional commands, e-mail: > lucene-user-help@jakarta.apache.org > __________________________________ Do you Yahoo!? The New Yahoo! Search - Faster. Easier. Bingo. http://search.yahoo.com --------------------------------------------------------------------- To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: lucene-user-help@jakarta.apache.org