public class ReturnNode extends Node
return return expression
Modifier and Type | Field and Description |
---|---|
protected @Nullable Node |
result |
protected ReturnTree |
tree |
Constructor and Description |
---|
ReturnNode(ReturnTree t,
@Nullable Node result,
Types types,
LambdaExpressionTree lambda,
com.sun.tools.javac.code.Symbol.MethodSymbol methodSymbol) |
ReturnNode(ReturnTree t,
@Nullable Node result,
Types types,
MethodTree methodTree) |
Modifier and Type | Method and Description |
---|---|
<R,P> R |
accept(NodeVisitor<R,P> visitor,
P p)
Accept method of the visitor pattern.
|
boolean |
equals(@Nullable Object obj) |
Collection<Node> |
getOperands()
|
@Nullable Node |
getResult()
The result of the return node,
null otherwise. |
ReturnTree |
getTree()
Returns the
Tree in the abstract syntax tree, or null if no corresponding
tree exists. |
int |
hashCode() |
String |
toString() |
getAssignmentContext, getBlock, getInSource, getTransitiveOperands, getType, isLValue, nodeCollectionToString, setAssignmentContext, setBlock, setInSource, setLValue, toStringDebug
protected final ReturnTree tree
public ReturnNode(ReturnTree t, @Nullable Node result, Types types, MethodTree methodTree)
public ReturnNode(ReturnTree t, @Nullable Node result, Types types, LambdaExpressionTree lambda, com.sun.tools.javac.code.Symbol.MethodSymbol methodSymbol)
public ReturnTree getTree()
Node
Tree
in the abstract syntax tree, or null
if no corresponding
tree exists. For instance, this is the case for an ImplicitThisLiteralNode
.public <R,P> R accept(NodeVisitor<R,P> visitor, P p)
Node
public Collection<Node> getOperands()
Node
getOperands
in class Node
Node
s of this Node