コード例 #1
0
        public override AbstractExpression AcceptRewriter(StatementRewriter rewriter)
        {
            var newCondition = Condition.AcceptRewriter(rewriter);
            var newWhenTrue  = WhenTrue.AcceptRewriter(rewriter);
            var newWhenFalse = WhenFalse.AcceptRewriter(rewriter);

            if (newCondition != Condition || newWhenTrue != WhenTrue || newWhenFalse != WhenFalse)
            {
                return(new ConditionalExpression {
                    Bindings = new BindingCollection(this.Bindings),
                    Type = this.Type,
                    Condition = newCondition,
                    WhenTrue = newWhenTrue,
                    WhenFalse = newWhenFalse
                });
            }

            return(this);
        }
コード例 #2
0
 public override AbstractStatement AcceptRewriter(StatementRewriter rewriter)
 {
     return(rewriter.RewriteDoStatement(this));
 }
コード例 #3
0
 public override AbstractExpression AcceptRewriter(StatementRewriter rewriter)
 {
     return(rewriter.RewriteBinaryExpression(this));
 }
コード例 #4
0
 IAssignable IAssignable.AcceptRewriter(StatementRewriter rewriter)
 {
     return((IAssignable)this.AcceptRewriter(rewriter));
 }
コード例 #5
0
 public override AbstractExpression AcceptRewriter(StatementRewriter rewriter)
 {
     return(rewriter.RewriteLocalVariableExpression(this));
 }
コード例 #6
0
 public abstract AbstractStatement AcceptRewriter(StatementRewriter rewriter);
コード例 #7
0
 public override AbstractExpression AcceptRewriter(StatementRewriter rewriter)
 {
     return(rewriter.RewriteObjectInitializerExpression(this));
 }
コード例 #8
0
        public override AbstractExpression AcceptRewriter(StatementRewriter rewriter)
        {
            var newType = rewriter.RewriteReferenceToTypeMember(TypeOperand);

            return(newType == TypeOperand ? this : new TypeReferenceExpression(newType));
        }
コード例 #9
0
 public abstract AbstractExpression AcceptRewriter(StatementRewriter rewriter);
コード例 #10
0
 public override AbstractExpression AcceptRewriter(StatementRewriter rewriter)
 {
     return(rewriter.RewriteDelegateInvocationExpression(this));
 }
コード例 #11
0
 public override AbstractExpression AcceptRewriter(StatementRewriter rewriter)
 {
     return(rewriter.RewriteInterpolatedStringExpression(this));
 }
コード例 #12
0
 IAssignable IAssignable.AcceptRewriter(StatementRewriter rewriter)
 {
     return(this);
 }
コード例 #13
0
 public override AbstractExpression AcceptRewriter(StatementRewriter rewriter)
 {
     return(rewriter.RewriteAnonymousDelegateExpression(this));
 }
コード例 #14
0
 public override AbstractStatement AcceptRewriter(StatementRewriter rewriter)
 {
     return(rewriter.RewriteVariableDeclaraitonStatement(this));
 }