public static RuleChaining And(this RuleChaining rule, RuleChaining innerCheck) { return(new RuleChaining() { Expression = rule.Expression.And(innerCheck.Expression) }); }
public static RuleChaining Or(this RuleChaining rule, IMatchingRule innerCheck) { var checkOtherRule = Expression.Call(Expression.Constant(innerCheck), _methodInfo, source, target); return(new RuleChaining() { Expression = rule.Expression.Or(checkOtherRule) }); }
public static RuleChaining Or(this IMatchingRule rule, RuleChaining innerCheck) { var checkRule = Expression.Call(Expression.Constant(rule), _methodInfo, source, target); return(new RuleChaining() { Expression = checkRule.Or(Expression.Invoke(innerCheck.Expression, source, target)) }); }