use of org.apache.lucene.queryparser.ext.ExtendableQueryParser in project fess by codelibs.
the class QueryHelperTest method setUp.
@Override
public void setUp() throws Exception {
super.setUp();
queryHelper = new QueryHelper() {
protected QueryParser getQueryParser() {
ExtendableQueryParser queryParser = new ExtendableQueryParser(Constants.DEFAULT_FIELD, new WhitespaceAnalyzer());
queryParser.setLowercaseExpandedTerms(false);
queryParser.setAllowLeadingWildcard(true);
queryParser.setDefaultOperator(QueryParser.Operator.AND);
return queryParser;
}
};
final FessConfig fessConfig = ComponentUtil.getFessConfig();
registerMockInstance(fessConfig);
registerMockInstance(new SystemHelper());
inject(queryHelper);
queryHelper.init();
}
Aggregations