예제 #1
0
        protected internal override Expression VisitConditionalMethodCall(ConditionalMethodCallCSharpExpression node)
        {
            var obj  = Visit(node.Object);
            var args = Visit(nameof(node.Arguments), node.Arguments, Visit);

            return(Push("CSharpConditionalCall", node, new XAttribute(nameof(node.Method), node.Method), new XElement(nameof(node.Object), obj), args));
        }
        private static ConditionalMethodCallCSharpExpression MakeConditionalMethodCall(Expression instance, MethodInfo method, IEnumerable <ParameterAssignment> arguments)
        {
            var argList = arguments.ToReadOnly();

            ValidateParameterBindings(method, argList, extensionMethod: method.IsStatic);

            return(ConditionalMethodCallCSharpExpression.Make(instance, method, argList));
        }
 public ConditionalMethodCallCSharpExpressionProxy(ConditionalMethodCallCSharpExpression node)
 {
     _node = node;
 }
 protected internal virtual Expression VisitConditionalMethodCall(ConditionalMethodCallCSharpExpression node)
 {
     return(node.Update(Visit(node.Expression), Visit(node.Arguments, VisitParameterAssignment)));
 }