[Java] Class ClosureListExpression
- org.codehaus.groovy.ast.expr.ClosureListExpression
This class represents a list of expressions used to create closures. Example:
def foo = (1;2;;)
The right side is a ClosureListExpression consisting of two ConstantExpressions for the values 1 and 2, and two EmptyStatement entries. The ClosureListExpression defines a new variable scope. All created Closures share this scope.
- Authors:
- Jochen Theodorou
Constructor Summary
Constructor and description |
---|
ClosureListExpression
(List<Expression> expressions) |
ClosureListExpression
() |
Methods Summary
Type Params | Return Type | Name and description |
---|---|---|
String |
getText() | |
VariableScope |
getVariableScope() | |
void |
setVariableScope(VariableScope scope) | |
Expression |
transformExpression(ExpressionTransformer transformer) | |
void |
visit(GroovyCodeVisitor visitor) |
Inherited Methods Summary
Methods inherited from class | Name |
---|---|
class ListExpression | addExpression, getExpression, getExpressions, getText, isWrapped, setWrapped, toString, transformExpression, visit |
class Expression | getType, setType, transformExpression, transformExpressions, transformExpressions |
class AnnotatedNode | addAnnotation, addAnnotations, getAnnotations, getAnnotations, getDeclaringClass, hasNoRealSourcePosition, isSynthetic, setDeclaringClass, setHasNoRealSourcePosition, setSynthetic |
class ASTNode | copyNodeMetaData, getColumnNumber, getLastColumnNumber, getLastLineNumber, getLineNumber, getNodeMetaData, getNodeMetaData, getText, putNodeMetaData, removeNodeMetaData, setColumnNumber, setLastColumnNumber, setLastLineNumber, setLineNumber, setNodeMetaData, setSourcePosition, visit |
class Object | wait, wait, wait, equals, toString, hashCode, getClass, notify, notifyAll |
Constructor Detail
public ClosureListExpression(List<Expression> expressions)
public ClosureListExpression()
Method Detail
public String getText()
public VariableScope getVariableScope()
public void setVariableScope(VariableScope scope)
public Expression transformExpression(ExpressionTransformer transformer)
public void visit(GroovyCodeVisitor visitor)
© 2003-2020 The Apache Software Foundation
Licensed under the Apache license.
https://docs.groovy-lang.org/2.4.21/html/gapi/org/codehaus/groovy/ast/expr/ClosureListExpression.html