Return-Path: Delivered-To: apmail-lucene-java-dev-archive@www.apache.org Received: (qmail 25531 invoked from network); 6 Apr 2006 14:05:17 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 6 Apr 2006 14:05:17 -0000 Received: (qmail 57783 invoked by uid 500); 6 Apr 2006 14:05:14 -0000 Delivered-To: apmail-lucene-java-dev-archive@lucene.apache.org Received: (qmail 57749 invoked by uid 500); 6 Apr 2006 14:05:14 -0000 Mailing-List: contact java-dev-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-dev@lucene.apache.org Delivered-To: mailing list java-dev@lucene.apache.org Received: (qmail 57736 invoked by uid 99); 6 Apr 2006 14:05:13 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 06 Apr 2006 07:05:13 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [12.154.210.214] (HELO rectangular.com) (12.154.210.214) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 06 Apr 2006 07:05:13 -0700 Received: from [67.189.26.9] (helo=[10.0.1.2]) by rectangular.com with esmtpa (Exim 4.44) id 1FRVYm-0007ja-CZ for java-dev@lucene.apache.org; Thu, 06 Apr 2006 07:34:08 -0700 Mime-Version: 1.0 (Apple Message framework v746.3) In-Reply-To: <20060406095213.13703.qmail@web26009.mail.ukl.yahoo.com> References: <20060406095213.13703.qmail@web26009.mail.ukl.yahoo.com> Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <347865A8-218F-42D1-93A6-306F5A3A544A@rectangular.com> Content-Transfer-Encoding: 7bit From: Marvin Humphrey Subject: Re: Query.extractTerms - a poor introspection API? Date: Thu, 6 Apr 2006 07:04:50 -0700 To: java-dev@lucene.apache.org X-Mailer: Apple Mail (2.746.3) X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N On Apr 6, 2006, at 2:52 AM, mark harwood wrote: > Maybe we should have as a standard part of Query: > > //immediate child queries only > Query [] getNestedQueries(); > > and... > //immediate terms only > Term [] getTerms(); FWIW: In KinoSearch, I have extract_terms set up to return either a Term, or in the case of PhraseQuery, a reference to an array of Terms. When the Highlighter sees the arrayref, it knows to winnow down the positions that the term appears at, using the same logic as PhraseScorer. This is what allows KinoSearch's Highlighter to handle phrases properly. http://www.rectangular.com/cgi-bin/uscon_search.cgi?q=%22united +states%22 http://lucenebook.com/search?query=%22united+states%22 Marvin Humphrey Rectangular Research http://www.rectangular.com/ --------------------------------------------------------------------- To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org For additional commands, e-mail: java-dev-help@lucene.apache.org