Return-Path: Delivered-To: apmail-lucene-java-user-archive@www.apache.org Received: (qmail 59264 invoked from network); 4 Jul 2008 13:13:50 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 4 Jul 2008 13:13:50 -0000 Received: (qmail 87248 invoked by uid 500); 4 Jul 2008 13:13:46 -0000 Delivered-To: apmail-lucene-java-user-archive@lucene.apache.org Received: (qmail 86220 invoked by uid 500); 4 Jul 2008 13:13:43 -0000 Mailing-List: contact java-user-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-user@lucene.apache.org Delivered-To: mailing list java-user@lucene.apache.org Received: (qmail 86209 invoked by uid 99); 4 Jul 2008 13:13:43 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 04 Jul 2008 06:13:43 -0700 X-ASF-Spam-Status: No, hits=0.2 required=10.0 tests=SPF_PASS,WHOIS_MYPRIVREG X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of yseeley@gmail.com designates 74.125.46.30 as permitted sender) Received: from [74.125.46.30] (HELO yw-out-2324.google.com) (74.125.46.30) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 04 Jul 2008 13:12:51 +0000 Received: by yw-out-2324.google.com with SMTP id 3so489271ywj.5 for ; Fri, 04 Jul 2008 06:13:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:sender :to:subject:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references :x-google-sender-auth; bh=vSyvEZiuMug7/pTZ7rxjiF+k1bcoQGVY6lpE+S+xzhU=; b=XrbBCNLpAftsnA+pWTXX1NH6YkrwHhnET2BGwBSMyMiK/X+1/RfjmGK7IL/WAtZ7c/ 4H0kqzkhUh0ZsJcaQNESamyk7I3HU5kR/Yn6lPEstNhxif6pfnSlObAusYmSoBSdiwG3 AtR/DLi7Gkchz/FLdrTTuKCDiKMo+o9eN9rms= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:sender:to:subject:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references:x-google-sender-auth; b=dAW0BaqEr5LEs6ghzDv0vMuR4rrFb/3Wsnist7bWJCezm74nmO5zAbcxYNJM2QC91V mDvZxYglZ5KaMWq/ooHa64nJUHZuI43AYbd2iAEmLelbefzvhpRiZp9SemJwkZKRKzG4 tAOHcCyV3RHjSHoxmCVxVEK5y3NM8J2r0NYJE= Received: by 10.151.110.9 with SMTP id n9mr1894489ybm.161.1215177190090; Fri, 04 Jul 2008 06:13:10 -0700 (PDT) Received: by 10.150.227.18 with HTTP; Fri, 4 Jul 2008 06:13:10 -0700 (PDT) Message-ID: Date: Fri, 4 Jul 2008 09:13:10 -0400 From: "Yonik Seeley" Sender: yseeley@gmail.com To: java-user@lucene.apache.org Subject: Re: Class in Lucene that Perform Search In-Reply-To: <18271691.post@talk.nabble.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <18250664.post@talk.nabble.com> <18253813.post@talk.nabble.com> <18271691.post@talk.nabble.com> X-Google-Sender-Auth: 0cdc84c4a42938fd X-Virus-Checked: Checked by ClamAV on apache.org Moving to java-user. Index the field and use the FieldCache. You don't want to modify core lucene classes for this common use-case. -Yonik On Thu, Jul 3, 2008 at 10:37 PM, blazingwolf7 wrote: > I am trying to retrieve the contentLength and the URL of each document from > the index without continuously using IndexReader, eg: > reader.document.get("ur"); > > I am trying to find a way to retrieve all this value and stored it into an > array by using the IndexReader only once or twice. I thought maybe I can > store some extra value into the .frq file then I will have no need to > continuously use the reader. Anyone can provide other suggestion? Thanks > > > Yonik Seeley wrote: >> >> On Thu, Jul 3, 2008 at 4:03 AM, blazingwolf7 >> wrote: >>> Ah, thanks! I am clear now. Have to change tactics to achieve what I >>> need. >>> Which class during indexing time will create the .frq file? >> >> DocumentsWriter (called from IndexWriter). >> >>> If possible, I want to add an extra value into it so that I can retrieve >>> the >>> information during the searching process. Thank >> >> Look at payloads first. >> What problem are you trying to solve? Someone may have an easier >> approach for you if payloads doesn't work. >> >> -Yonik >> >> >> >>> >>> Yonik Seeley wrote: >>>> >>>> On Wed, Jul 2, 2008 at 10:30 PM, blazingwolf7 >>>> wrote: >>>>> What I am missing is that I fail to locate the class that perform the >>>>> actual >>>>> comparison to determine if a query match any term in a document. >>>> >>>> You need to understand the inverted index format. Documents that >>>> match a term is determined at index time, not at query time. The .frq >>>> file lists all documents that match each term. >>>> >>>> TermDocs iterates over all documents that match the term by reading >>>> the .frq file. >>>> >>>> -Yonik >>>> >>>> --------------------------------------------------------------------- >>>> To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org >>>> For additional commands, e-mail: java-dev-help@lucene.apache.org >>>> >>>> >>>> >>> >>> -- >>> View this message in context: >>> http://www.nabble.com/Class-in-Lucene-that-Perform-Search-tp18250664p18253813.html >>> Sent from the Lucene - Java Developer mailing list archive at Nabble.com. >>> >>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org >>> For additional commands, e-mail: java-dev-help@lucene.apache.org >>> >>> >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org >> For additional commands, e-mail: java-dev-help@lucene.apache.org >> >> >> > > -- > View this message in context: http://www.nabble.com/Class-in-Lucene-that-Perform-Search-tp18250664p18271691.html > Sent from the Lucene - Java Developer mailing list archive at Nabble.com. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org > For additional commands, e-mail: java-dev-help@lucene.apache.org > > --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org For additional commands, e-mail: java-user-help@lucene.apache.org