C# 클래스 Rhino.Ast.ConditionalExpression

AST node representing the ternary operator.
AST node representing the ternary operator. Node type is Rhino.Token.HOOK .
ConditionalExpression : LogicalORExpression LogicalORExpression ? AssignmentExpression : AssignmentExpression
ConditionalExpressionNoIn : LogicalORExpressionNoIn LogicalORExpressionNoIn ? AssignmentExpression : AssignmentExpressionNoIn
상속: AstNode
파일 보기 프로젝트 열기: hazzik/Rhino.Net 1 사용 예제들

공개 메소드들

메소드 설명
ConditionalExpression ( ) : System.Text
ConditionalExpression ( int pos ) : System.Text
ConditionalExpression ( int pos, int len ) : System.Text
GetColonPosition ( ) : int

Returns position of : token

GetFalseExpression ( ) : AstNode

Returns expression to evaluate if test is false

GetQuestionMarkPosition ( ) : int

Returns position of ? token

GetTestExpression ( ) : AstNode

Returns test expression

GetTrueExpression ( ) : AstNode

Returns expression to evaluate if test is true

HasSideEffects ( ) : bool
SetColonPosition ( int colonPosition ) : void

Sets position of : token

SetFalseExpression ( AstNode falseExpression ) : void

Sets expression to evaluate if test is false, and sets its parent to this node.

Sets expression to evaluate if test is false, and sets its parent to this node.

SetQuestionMarkPosition ( int questionMarkPosition ) : void

Sets position of ? token

SetTestExpression ( AstNode testExpression ) : void

Sets test expression, and sets its parent.

Sets test expression, and sets its parent.

SetTrueExpression ( AstNode trueExpression ) : void

Sets expression to evaluate if test is true, and sets its parent to this node.

Sets expression to evaluate if test is true, and sets its parent to this node.

ToSource ( int depth ) : string
Visit ( NodeVisitor v ) : void

Visits this node, then the test-expression, the true-expression, and the false-expression.

Visits this node, then the test-expression, the true-expression, and the false-expression.

메소드 상세

ConditionalExpression() 공개 메소드

public ConditionalExpression ( ) : System.Text
리턴 System.Text

ConditionalExpression() 공개 메소드

public ConditionalExpression ( int pos ) : System.Text
pos int
리턴 System.Text

ConditionalExpression() 공개 메소드

public ConditionalExpression ( int pos, int len ) : System.Text
pos int
len int
리턴 System.Text

GetColonPosition() 공개 메소드

Returns position of : token
public GetColonPosition ( ) : int
리턴 int

GetFalseExpression() 공개 메소드

Returns expression to evaluate if test is false
public GetFalseExpression ( ) : AstNode
리턴 AstNode

GetQuestionMarkPosition() 공개 메소드

Returns position of ? token
public GetQuestionMarkPosition ( ) : int
리턴 int

GetTestExpression() 공개 메소드

Returns test expression
public GetTestExpression ( ) : AstNode
리턴 AstNode

GetTrueExpression() 공개 메소드

Returns expression to evaluate if test is true
public GetTrueExpression ( ) : AstNode
리턴 AstNode

HasSideEffects() 공개 메소드

public HasSideEffects ( ) : bool
리턴 bool

SetColonPosition() 공개 메소드

Sets position of : token
public SetColonPosition ( int colonPosition ) : void
colonPosition int position of : token
리턴 void

SetFalseExpression() 공개 메소드

Sets expression to evaluate if test is false, and sets its parent to this node.
Sets expression to evaluate if test is false, and sets its parent to this node.
/// if /// falseExpression /// is /// null ///
public SetFalseExpression ( AstNode falseExpression ) : void
falseExpression AstNode expression to evaluate if test is false
리턴 void

SetQuestionMarkPosition() 공개 메소드

Sets position of ? token
public SetQuestionMarkPosition ( int questionMarkPosition ) : void
questionMarkPosition int position of ? token
리턴 void

SetTestExpression() 공개 메소드

Sets test expression, and sets its parent.
Sets test expression, and sets its parent.
/// if testExpression is /// null ///
public SetTestExpression ( AstNode testExpression ) : void
testExpression AstNode test expression
리턴 void

SetTrueExpression() 공개 메소드

Sets expression to evaluate if test is true, and sets its parent to this node.
Sets expression to evaluate if test is true, and sets its parent to this node.
/// if expression is /// null ///
public SetTrueExpression ( AstNode trueExpression ) : void
trueExpression AstNode expression to evaluate if test is true
리턴 void

ToSource() 공개 메소드

public ToSource ( int depth ) : string
depth int
리턴 string

Visit() 공개 메소드

Visits this node, then the test-expression, the true-expression, and the false-expression.
Visits this node, then the test-expression, the true-expression, and the false-expression.
public Visit ( NodeVisitor v ) : void
v NodeVisitor
리턴 void