Return-Path: Delivered-To: apmail-lucene-java-user-archive@www.apache.org Received: (qmail 48197 invoked from network); 24 May 2007 18:05:53 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 24 May 2007 18:05:53 -0000 Received: (qmail 74196 invoked by uid 500); 24 May 2007 18:05:41 -0000 Delivered-To: apmail-lucene-java-user-archive@lucene.apache.org Received: (qmail 74170 invoked by uid 500); 24 May 2007 18:05:41 -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 74034 invoked by uid 99); 24 May 2007 18:05:39 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 24 May 2007 11:05:39 -0700 X-ASF-Spam-Status: No, hits=2.0 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: domain of carlosjosepita@gmail.com designates 209.85.132.240 as permitted sender) Received: from [209.85.132.240] (HELO an-out-0708.google.com) (209.85.132.240) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 24 May 2007 11:05:31 -0700 Received: by an-out-0708.google.com with SMTP id b20so96636ana for ; Thu, 24 May 2007 11:04:48 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; b=UjVxA6q8RQQDVlfQyHcDlBhahM2HxCFJbZqdpgkBzVujN7Ub3Z+t/vSdQxfpy1w0Uo5OrO3T09Rj0k1JmbXZj4xOBdPTWZWVY4JHhsglBo0n31hAx2H+up6yXWw5lMcNbHflKa6gzLw/nCnRpQr7r4+Y+Xkx6PA5FJ9fVQaeaus= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; b=UipHfiw0J+7GkvBWvdGRAUKLYH1faTgoAm+ztwUQhaoglvt6NDEmDOHzNceVSSmlOFX5iOk32NN5TLEdqG71AyTYquERM3qVGXigeQHjmbPmwhrVpg9zaomjxnDAMIw9qBweSzTaxeEXiEqb+pkeEO90BxAsE4dMVmxnpQLp/5o= Received: by 10.114.171.1 with SMTP id t1mr1035492wae.1180029888179; Thu, 24 May 2007 11:04:48 -0700 (PDT) Received: by 10.114.14.6 with HTTP; Thu, 24 May 2007 11:04:48 -0700 (PDT) Message-ID: <7798eaa0705241104h1f2c1984kb21f85802ac67477@mail.gmail.com> Date: Thu, 24 May 2007 15:04:48 -0300 From: "Carlos Pita" To: java-user@lucene.apache.org Subject: Re: maxDoc and arrays In-Reply-To: <359a92830705241025t583bb657jbde1a1776bc1546a@mail.gmail.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_146283_13240037.1180029888128" References: <7798eaa0705240941y5b420dd3sb2867ed86008dc19@mail.gmail.com> <359a92830705241025t583bb657jbde1a1776bc1546a@mail.gmail.com> X-Virus-Checked: Checked by ClamAV on apache.org ------=_Part_146283_13240037.1180029888128 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline > > Why wouldn't numdocs serve? Because the document id (which is the array index) would be in the range 0 ... maxDoc and not 0 ... numDocs, wouldn't it? Cheers, Carlos Best > Erick > > > The motivation of this question is that I want to associate some info to > > each document in the index, and in order to access this additional data > in > > O(1) I would like to do this through an array indexing. But the array > size > > shouldn't be a lot greater than the total number of documents. I see > that > > something similar is done in the example of section 6.1 of Lucene in > > Action, > > but for sorting purposes, which is not my case. > > > > Related to this: how can update my array of extra data when documents > are > > added/removed to/from the index? Is there any feedback mechanism by > means > > of > > callbacks or event handlers? > > > > Thank you in advance. > > Regards, > > Carlos > > > ------=_Part_146283_13240037.1180029888128--