private LuceneQueryModel PrepareQuery(QueryModel queryModel) { QueryModelTransformer.TransformQueryModel(queryModel); var builder = new QueryModelTranslator(this, context); builder.Build(queryModel); Log.Debug(() => string.Format("Lucene query: {0}", builder.Model)); return(builder.Model); }
private LuceneQueryModel PrepareQuery(QueryModel queryModel) { QueryModelTransformer.TransformQueryModel(queryModel); var builder = new QueryModelTranslator(this); builder.Build(queryModel); Log.Debug(m => m("Lucene query: {0}", builder.Model)); return(builder.Model); }
public void SetUp() { mocks = new MockRepository(); visitor1 = mocks.StrictMock <ExpressionTreeVisitor>(); visitor2 = mocks.StrictMock <ExpressionTreeVisitor>(); var visitors = new[] { visitor1, visitor2 }; transformer = new QueryModelTransformer(visitors, visitors); using (mocks.Ordered()) { visitor1.Expect(v => v.VisitExpression(whereClause.Predicate)).Return(whereClause.Predicate); visitor2.Expect(v => v.VisitExpression(whereClause.Predicate)).Return(whereClause.Predicate); } mocks.ReplayAll(); }