public override bool IsValid(Expression expression) { _expressionFinder = new ExpressionFinder(this); _expressionFinder.Visit(expression); return(_expressionFinder.FoundExpressions.Any()); }
public static bool Find(Expression expression, Predicate <Expression> predicate) { var f = new ExpressionFinder(predicate); f.Visit(expression); return(f.Found); }
public override bool IsValid(Expression expression) { _expressionFinder = new ExpressionFinder(this); if (IsQueryableResult(expression)) { _expressionFinder.TryAddType(expression.Type.GetGenericArguments()[0]); _expressionFinder.Visit(expression); } return(_expressionFinder.FoundExpressions.Any()); }