Return-Path: Delivered-To: apmail-lucene-solr-dev-archive@minotaur.apache.org Received: (qmail 27957 invoked from network); 28 Aug 2009 17:17:24 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 28 Aug 2009 17:17:24 -0000 Received: (qmail 12638 invoked by uid 500); 28 Aug 2009 14:27:23 -0000 Delivered-To: apmail-lucene-solr-dev-archive@lucene.apache.org Received: (qmail 12563 invoked by uid 500); 28 Aug 2009 14:27:23 -0000 Mailing-List: contact solr-dev-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: solr-dev@lucene.apache.org Delivered-To: mailing list solr-dev@lucene.apache.org Received: (qmail 12553 invoked by uid 99); 28 Aug 2009 14:27:23 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 28 Aug 2009 14:27:23 +0000 X-ASF-Spam-Status: No, hits=1.2 required=10.0 tests=SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (athena.apache.org: local policy) Received: from [208.97.132.207] (HELO spunkymail-a3.g.dreamhost.com) (208.97.132.207) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 28 Aug 2009 14:27:14 +0000 Received: from [10.0.0.77] (adsl-065-013-152-164.sip.rdu.bellsouth.net [65.13.152.164]) by spunkymail-a3.g.dreamhost.com (Postfix) with ESMTP id AC17B15D4EA for ; Fri, 28 Aug 2009 07:26:53 -0700 (PDT) Message-Id: <4DBC830F-8F78-43F7-9797-CD4F42369F59@apache.org> From: Grant Ingersoll To: solr-dev@lucene.apache.org Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v936) Subject: Mucking with DocSlices Date: Fri, 28 Aug 2009 10:26:52 -0400 X-Mailer: Apple Mail (2.936) X-Virus-Checked: Checked by ClamAV on apache.org I'd like to be able to change the DocList in a SearchComponent, for instance to shorten or lengthen it. I can get a shorter one via the subset() method, but the problem with this is the new subset still reflects the number of matches, etc. of the parent, which seems a little odd to me. If I say String.substring().length(), I wouldn't expect the length returned to be the same as the parent (unless of course the substring requested is the identity one), so I'm not sure why DocSlice.subset does. Likewise for the maxScore, etc. Is there a reason why, if I know I have a DocSlice, I can't cast the docList to it and make some of these lower level changes to the member variables? It would be a lot more efficient than having to copy over all the docs, etc. to a new DocSlice. Thanks, Grant