internal void AddUnion(LambdaQueryBase query2, UnionType unionType) { if (unionType == UnionType.None) { throw new CRLException("没有指定UnionType"); } __Unions.Add(new UnionQuery() { query = query2, unionType = unionType }); foreach (var kv in query2.QueryParames) { QueryParames[kv.Key] = kv.Value; } }
internal void AddUnion(LambdaQueryBase query2, UnionType unionType) { if (unionType == UnionType.None) { throw new CRLException("没有指定UnionType"); } __Unions = __Unions ?? new List <UnionQuery>(); __Unions.Add(new UnionQuery() { query = query2, unionType = unionType }); QueryParames.AddRange(query2.QueryParames); //foreach (var kv in query2.QueryParames) //{ // QueryParames[kv.Item1] = kv.Item2; //} }
/// <summary> /// 关联查询分支 /// </summary> /// <param name="query"></param> internal LambdaQueryJoin(LambdaQueryBase query) { BaseQuery = query; }
internal LambdaQueryResultSelect(LambdaQueryBase query, Expression _resultSelectorBody) { resultSelectorBody = _resultSelectorBody; BaseQuery = query; }
public ExpressionVisitor(LambdaQueryBase _lambdaQueryBase) { lambdaQueryBase = _lambdaQueryBase; __DBAdapter = lambdaQueryBase.__DBAdapter; dbContext = __DBAdapter.dbContext; }
public ExpressionVisitor(LambdaQueryBase _lambdaQueryBase) { lambdaQueryBase = _lambdaQueryBase; }
internal GroupQuery(LambdaQueryBase query) { BaseQuery = query; }
/// <summary> /// 按筛选返回匿名对象 /// </summary> /// <typeparam name="TResult"></typeparam> /// <param name="query"></param> /// <param name="newExpression"></param> /// <returns></returns> public abstract List <TResult> QueryResult <TResult>(LambdaQuery.LambdaQueryBase query, NewExpression newExpression);
/// <summary> /// 关联查询分支 /// </summary> /// <param name="query"></param> public LambdaQueryJoin(LambdaQueryBase query) { BaseQuery = query; }
/// <summary> /// 返回多项结果 /// </summary> /// <typeparam name="TModel"></typeparam> /// <param name="query"></param> /// <param name="cacheKey"></param> /// <returns></returns> public abstract List <TModel> QueryOrFromCache <TModel>(LambdaQuery.LambdaQueryBase query, out string cacheKey) where TModel : CRL.IModel, new();
/// <summary> /// 关联查询分支 /// </summary> /// <param name="query"></param> /// <param name="_resultSelect"></param> internal LambdaQueryViewJoin(LambdaQuery <T> query, ILambdaQueryResultSelect <TJoinResult> _resultSelect) { BaseQuery = query; resultSelect = _resultSelect; }
/// <summary> /// 返回指定对象 /// </summary> /// <typeparam name="TResult"></typeparam> /// <param name="query"></param> /// <returns></returns> public abstract List <TResult> QueryResult <TResult>(CRL.LambdaQuery.LambdaQueryBase query);
/// <summary> /// 返回动态对象 /// </summary> /// <param name="query"></param> /// <returns></returns> public abstract List <dynamic> QueryDynamic(CRL.LambdaQuery.LambdaQueryBase query);