On Oct 4, 2004, at 2:12 PM, Chris Fraschetti wrote:
absoultely, limiting the user's query is no problem here. I've currently implemented the lucene javascript to catcha lot of user quries that could cause issues.. blank queries, ? or * at the beginning of query, etc etc... but I couldn't think of a way to prevent the user from doing a* but not comment* wanting comments or commentary... any suggestions would be warmly welcomed.
I recommend subclassing QueryParser, and overriding getPrefixQuery and getWildcardQuery. In both of the overridden methods, throw a ParseException. You should be handling ParseException gracefully somehow already, so that should do the trick.
Erik
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]