lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chris Hostetter <hossman_luc...@fucit.org>
Subject Re: Access to the TermEnum collection outside OAL package
Date Wed, 02 Apr 2008 19:02:21 GMT

:   I did like this:
:   - for each term to find, build a FuzzyQuery object like this:
:        fq = new FuzzyQuery(new Term("contents", queryString), minSimilarity) 
:   - as the FuzzyQuery.getEnum() method is protected - and my program is
:      in another package, I added a getEnumWrapper() method to the FuzzyQuery
:      class. It does the same as getEnum() - returns a FilteredTermEnum
: collection
:      but it's public.
:   - finally, the program iterates through all the items returned by
: getEnumWrapper()
:      displaying the best matches.

it sounds like you aren't executing the FuzzyQuery at all ... just 
enumerating over theterms, correct?

Do you really need the FuzzyQuery object at all? 
why not just construct a FuzzyTermEnum directly? (it's a public class).


BTW...
   http://people.apache.org/~hossman/#java-dev
Please Use "java-user@lucene" Not "java-dev@lucene"

Your question is better suited for the java-user@lucene mailing list ...
not the java-dev@lucene list.  java-dev is for discussing development of
the internals of the Lucene Java library ... it is *not* the appropriate
place to ask questions about how to use the Lucene Java library when
developing your own applications. 



-Hoss


---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-dev-help@lucene.apache.org


Mime
View raw message