Package org.jruby.ast
Class IfNode
java.lang.Object
org.jruby.ast.Node
org.jruby.ast.IfNode
an 'if' statement.
-
Field Summary
Fields inherited from class org.jruby.ast.Node
containsVariableAssignment, newline
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<T> T
accept
(NodeVisitor<T> iVisitor) Accept for the visitor pattern.Gets the condition.Gets the elseBody.Gets the thenBody.Methods inherited from class org.jruby.ast.Node
containsVariableAssignment, createList, createList, createList, createList, executesOnce, getFile, getLine, getNodeName, isNewline, isNil, needsDefinitionCheck, setLine, setNewline, toString, toString, toStringExtraInfo, toStringInternal, unsetNewline
-
Constructor Details
-
IfNode
-
-
Method Details
-
getNodeType
- Specified by:
getNodeType
in classNode
- Returns:
- the nodeId
-
accept
Accept for the visitor pattern. -
getCondition
Gets the condition.- Returns:
- Returns a Node
-
getElseBody
Gets the elseBody.- Returns:
- Returns a Node
-
getThenBody
Gets the thenBody.- Returns:
- Returns a Node
-
childNodes
- Specified by:
childNodes
in classNode
-