[
https://issues.apache.org/jira/browse/LUCENE-3121?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Michael McCandless updated LUCENE-3121:
---------------------------------------
Attachment: LUCENE-3121.patch
Patch, adding Util.getByOutput. I think it's ready.
It only works w/ an FST whose outputs are strictly monotonically increasing w/
the inputs.
Currently it only works with FST<Long> but we can "generify" that at some
point...
This is only the "exact" case; in theory we could do floor/ceiling too, but
it'd be just as hairy as seekFloor/seekCeil in FSTEnum... let's wait for a real
need.
> FST should offer lookup-by-output API when output strictly increases
> --------------------------------------------------------------------
>
> Key: LUCENE-3121
> URL: https://issues.apache.org/jira/browse/LUCENE-3121
> Project: Lucene - Java
> Issue Type: Improvement
> Components: core/other
> Reporter: Michael McCandless
> Assignee: Michael McCandless
> Fix For: 4.0
>
> Attachments: LUCENE-3121.patch
>
>
> Spinoff from "FST and FieldCache" java-dev thread
> http://lucene.markmail.org/thread/swoawlv3fq4dntvl
> FST is able to associate arbitrary outputs with the sorted input keys, but in
> the special (and, common) case where the function is strictly monotonic (each
> output only "increases" vs prior outputs), such as mapping to term ords or
> mapping to file offsets in the terms dict, we should offer a lookup-by-output
> API that efficiently walks the FST and locates input key (exact or floor or
> ceil) matching that output.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]