public static Expression Build(QueryLinguist linguist, QueryPolicy policy, Expression expression, Expression provider) { var executor = Expression.Parameter(typeof(QueryExecutor), "executor"); var builder = new ExecutionBuilder(linguist, policy, executor); builder.variables.Add(executor); builder.initializers.Add(Expression.Call(Expression.Convert(provider, typeof(ICreateExecutor)), "CreateExecutor", null, null)); var result = builder.Build(expression); return(result); }
private RelationshipIncluder(QueryMapper mapper) { this.mapper = mapper; this.policy = mapper.Translator.Police.Policy; }
public static Expression Rewrite(QueryPolicy policy, QueryLanguage language, Expression expression) { return(new ClientJoinedProjectionRewriter(policy, language).Visit(expression)); }
private ClientJoinedProjectionRewriter(QueryPolicy policy, QueryLanguage language) { this.policy = policy; this.language = language; }
private ExecutionBuilder(QueryLinguist linguist, QueryPolicy policy, Expression executor) { this.linguist = linguist; this.policy = policy; this.executor = executor; }
public QueryTranslator(QueryLanguage language, QueryMapping mapping, QueryPolicy policy) { this.linguist = language.CreateLinguist(this); this.mapper = mapping.CreateMapper(this); this.police = policy.CreatePolice(this); }
public QueryPolice(QueryPolicy policy, QueryTranslator translator) { this.policy = policy; this.translator = translator; }