That does help - I'll take a close look at both of the classes you suggested. Thanks Doug.
Andrew On Mon, 30 Aug 2004 13:11:31 -0700, Doug Cutting <[EMAIL PROTECTED]> wrote: > Andrew Chen wrote: > > Don't know if anyone else has been building QueryFilter extensions, > > but here's a quick question. In the filter method that needs to be > > implemented as part of the QueryFilter interface, the method looks > > like this: > > > > public BooleanQuery filter(Query input, BooleanQuery translation) > > > > Query is a Nutch class and BooleanQuery is a Lucene class, and as far > > as I can tell, there isn't a straightforward way to make them talk to > > each other. > > That's what query filters are for: to translate Nutch queries into > Lucene queries. The Nutch Query passed in is what Nutch's query parser > built from the user's input. The BooleanQuery is what other translators > have built so far, and the returned result is the modified version of > this that this filter constructs. > > > No examples to help either :( The plugins that come with v0.5 use the > > RawFieldQueryFilter... > > Did you look at the implementation of RawFieldQueryFilter? Or the > implementation of BasicQueryFilter, in query-basic? What these do is > iterate through the clauses of the Nutch query, looking for clauses that > they're responsible for, and adding corresponding clauses to the > resulting Lucene BooleanQuery. > > Does that help? > > Doug > > ------------------------------------------------------- > This SF.Net email is sponsored by BEA Weblogic Workshop > FREE Java Enterprise J2EE developer tools! > Get your free copy of BEA WebLogic Workshop 8.1 today. > http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click > _______________________________________________ > Nutch-developers mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/nutch-developers > ------------------------------------------------------- This SF.Net email is sponsored by BEA Weblogic Workshop FREE Java Enterprise J2EE developer tools! Get your free copy of BEA WebLogic Workshop 8.1 today. http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click _______________________________________________ Nutch-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nutch-developers
