lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hoss Man (JIRA)" <>
Subject [jira] Commented: (LUCENE-1435) CollationKeyFilter: convert tokens into CollationKeys encoded using IndexableBinaryStringTools
Date Sat, 01 Nov 2008 18:23:44 GMT


Hoss Man commented on LUCENE-1435:

The one worry i have about an approach like this comes from the fine print of the CollationKey

bq. You can only compare CollationKeys generated from the same Collator object.

"same" tends to have a very specific meaning in Java documentation, .. it's usually used to
indicate refrence equality (ie "==" not .equals) ...

bq. The equals method for class Object implements the most discriminating possible equivalence
relation on objects; that is, for any non-null reference values x and y, this method returns
true if and only if x and y refer to the same object (x == y has the value true).

so the question becomes: did they reall mean "same Collator" or did they mean "a Collator
with the same rules" ? 

is it safe to persist a CollationKey from a Collator A and then compare it with a CollationKey
from another Collator B where A.equals(B) but A != B (because A and B are from different JVM

> CollationKeyFilter: convert tokens into CollationKeys encoded using IndexableBinaryStringTools
> ----------------------------------------------------------------------------------------------
>                 Key: LUCENE-1435
>                 URL:
>             Project: Lucene - Java
>          Issue Type: New Feature
>    Affects Versions: 2.4
>            Reporter: Steven Rowe
>            Priority: Minor
>             Fix For: 2.9
>         Attachments: LUCENE-1435.patch
> Converts each token into its CollationKey using the provided collator, and then encodes
the CollationKey with IndexableBinaryStringTools, to allow it to be stored as an index term.
> This will allow for efficient range searches and Sorts over fields that need collation
for proper ordering.

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:
For additional commands, e-mail:

View raw message