摘要: 使用场景:多条件筛选,不确定条件的个数时,可选择此种方式; 扩展类: public static class ExpLinqExpressions { public static Expression<Func<T, bool>> True<T>() { return f => true; } pu 阅读全文
posted @ 2021-11-04 16:44 艾特-天空之海 阅读(211) 评论(0) 推荐(0) 编辑
摘要: ///查询数据库的仓储类 ItestRepository test = new TestRepository(); ParameterExpression parameterExpression = Expression.Parameter(typeof(Test), "d"); PropertyI 阅读全文
posted @ 2021-11-04 16:36 艾特-天空之海 阅读(51) 评论(0) 推荐(0) 编辑
摘要: Program是一个类;这行代码的结果是找到这个类的绝对路径; string test = typeof(Program).Assembly.Location; 阅读全文
posted @ 2021-11-04 10:20 艾特-天空之海 阅读(71) 评论(0) 推荐(0) 编辑