コード例 #1
0
        public override bool IsValid(Expression expression)
        {
            _expressionFinder = new ExpressionFinder(this);
            _expressionFinder.Visit(expression);

            return(_expressionFinder.FoundExpressions.Any());
        }
コード例 #2
0
            public static bool Find(Expression expression, Predicate <Expression> predicate)
            {
                var f = new ExpressionFinder(predicate);

                f.Visit(expression);
                return(f.Found);
            }
コード例 #3
0
        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());
        }