Beispiel #1
0
        public Map(Expression <Func <TB, T> > memberAccessExpression, PredicateBase <T> then)
        {
            Then         = then;
            PropertyPath = memberAccessExpression.ToPropertyPath();

            // TODO: Adapt for expression with more than one parameter.
            ParameterName = memberAccessExpression.Parameters.FirstOrDefault()?.Name;
        }
Beispiel #2
0
 public PredicateBase <TB> Is(PredicateBase <T> predicate)
 {
     return(new Map <T, TB>(_source, predicate));
 }
Beispiel #3
0
 public static PredicateBase <T> Or <T>(this PredicateBase <T> left, PredicateBase <T> right)
 {
     return(new Any <T>(left, right));
 }
Beispiel #4
0
 public static PredicateBase <T> And <T>(this PredicateBase <T> left, PredicateBase <T> right)
 {
     return(new All <T>(left, right));
 }
Beispiel #5
0
 public Map(string propertyPath, PredicateBase <T> then)
 {
     Then         = then;
     PropertyPath = propertyPath;
 }