lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ryan McKinley (JIRA)" <j...@apache.org>
Subject [jira] Updated: (LUCENE-2671) Add sort missing first/last ability to SortField and ValueComparator
Date Thu, 14 Oct 2010 00:29:32 GMT

     [ https://issues.apache.org/jira/browse/LUCENE-2671?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Ryan McKinley updated LUCENE-2671:
----------------------------------

    Attachment: LUCENE-2671-suppress-unchecked.patch

here is a patch that ignores all the unchecked casts
{code:java}
 @SuppressWarnings("unchecked")
{code}

I don't think there is any way around this for the current design -- in LUCENE-2665, the cache
would directly use the generic map, but for the baby step it needs a cast.

The issues is that we have:
{code:java}
private Map<Class<?>,Cache> caches;
{code}

and really need to be able to define something like:
{code:java}
private Map<Class<X>,Cache<? extends X>> caches;
{code}
where X depends on what you put into the map...  but that is not possible as far as I know.

- - -

I would commit this, but the build is failing for other reasons....  



> Add sort missing first/last ability to SortField and ValueComparator
> --------------------------------------------------------------------
>
>                 Key: LUCENE-2671
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2671
>             Project: Lucene - Java
>          Issue Type: New Feature
>          Components: Search
>            Reporter: Ryan McKinley
>            Assignee: Ryan McKinley
>             Fix For: 4.0
>
>         Attachments: LUCENE-2671-SortMissingLast.patch, LUCENE-2671-suppress-unchecked.patch
>
>
> When SortField and ValueComparator use EntryCreators (from LUCENE-2649) they use a special
sort value when the field is missing.
> This enables lucene to implement 'sort missing last' or 'sort missing first' for numeric
values from the FieldCache.

-- 
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-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


Mime
View raw message