[ 
https://issues.apache.org/jira/browse/LUCENE-2649?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12913709#action_12913709
 ] 

Uwe Schindler commented on LUCENE-2649:
---------------------------------------

It's not more complicated its easier. The Bits are a real separate thing, its 
just a cache of the information, if values are assigned or not. It does not 
depend on the data type like byte, int,... Its just separate. And as said 
before, if somebody requests the same field in different types, it would only 
have one bits. Also one could request the Bits alone, or could first request a 
field without bits (using a boolean) and later again with bits, in which case 
those are lazily loaded

Th implementation would be simple, similar to the way, how the caches are 
filled for NumericFields (it adds the values two times to the cache, with the 
null parser and the real used parser). I this case youl would simply request 
the bits cache on e.g. the int[] creation, if not availabe, also build the bits 
in parallel and add to bits cache.

> FieldCache should include a BitSet for matching docs
> ----------------------------------------------------
>
>                 Key: LUCENE-2649
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2649
>             Project: Lucene - Java
>          Issue Type: Improvement
>            Reporter: Ryan McKinley
>             Fix For: 4.0
>
>         Attachments: LUCENE-2649-FieldCacheWithBitSet.patch, 
> LUCENE-2649-FieldCacheWithBitSet.patch, 
> LUCENE-2649-FieldCacheWithBitSet.patch, 
> LUCENE-2649-FieldCacheWithBitSet.patch, LUCENE-2649-FieldCacheWithBitSet.patch
>
>
> The FieldCache returns an array representing the values for each doc.  
> However there is no way to know if the doc actually has a value.
> This should be changed to return an object representing the values *and* a 
> BitSet for all valid docs.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to