I have a trivial extension to MultiSearcher that allows you to use more
than a single query. Currently, I can only find a way to apply a single
query across multiple databases. I have heterogeneous databases that
require different queries (well, slightly but enough) be applied for
each database. I made a subclass whose constructor takes both an array
of searchers and array of queries. I then override

TopDocs search(Query query /* ignored */, Filter filter, int
nDocs) {...}

to use

TopDocs docs = searchers[i].search(queries[i], filter,

instead of

TopDocs docs = searchers[i].search(queries, filter, nDocs);

Doug: can you tell me why MultiSearcher is final? It makes it pretty
hard to specialize your work ;)

Am i missing an existing way to do this?

Thanks again for a great product...jGuru is better for it's use of
Lucene. :)

It's trivial, but does anybody want the simple class? Should it be
included in the next release candidate? Am I the only one that wants
multiple databases with different structures?

Chief Scientist & Co-founder, http://www.jguru.com
Creator, ANTLR Parser Generator: http://www.antlr.org

To unsubscribe, e-mail:
For additional commands, e-mail:

Search Discussions

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 1 of 1 | next ›
Discussion Overview
groupjava-user @
postedFeb 7, '02 at 10:35p
activeFeb 7, '02 at 10:35p

1 user in discussion

Terence Parr: 1 post



site design / logo © 2022 Grokbase