Package org.sonar.python.tree
Class LambdaExpressionImpl
- java.lang.Object
-
- org.sonar.python.tree.PyTree
-
- org.sonar.python.tree.LambdaExpressionImpl
-
- All Implemented Interfaces:
Expression,FunctionLike,LambdaExpression,Tree
public class LambdaExpressionImpl extends PyTree implements LambdaExpression
-
-
Field Summary
-
Fields inherited from class org.sonar.python.tree.PyTree
firstToken, lastToken
-
-
Constructor Summary
Constructors Constructor Description LambdaExpressionImpl(Token lambdaKeyword, Token colonToken, Expression body, ParameterList parameterList)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaccept(TreeVisitor visitor)voidaddLocalVariableSymbol(Symbol symbol)TokencolonToken()List<Tree>computeChildren()Expressionexpression()Tree.KindgetKind()booleanisMethodDefinition()TokenlambdaKeyword()Set<Symbol>localVariables()ParameterListparameters()-
Methods inherited from class org.sonar.python.tree.PyTree
children, firstToken, is, lastToken, parent, setParent
-
-
-
-
Constructor Detail
-
LambdaExpressionImpl
public LambdaExpressionImpl(Token lambdaKeyword, Token colonToken, Expression body, @Nullable ParameterList parameterList)
-
-
Method Detail
-
lambdaKeyword
public Token lambdaKeyword()
- Specified by:
lambdaKeywordin interfaceLambdaExpression
-
colonToken
public Token colonToken()
- Specified by:
colonTokenin interfaceLambdaExpression
-
expression
public Expression expression()
- Specified by:
expressionin interfaceLambdaExpression
-
parameters
@CheckForNull public ParameterList parameters()
- Specified by:
parametersin interfaceFunctionLike
-
localVariables
public Set<Symbol> localVariables()
- Specified by:
localVariablesin interfaceFunctionLike- Returns:
- symbols of local variables and parameters
-
isMethodDefinition
public boolean isMethodDefinition()
- Specified by:
isMethodDefinitionin interfaceFunctionLike
-
addLocalVariableSymbol
public void addLocalVariableSymbol(Symbol symbol)
-
accept
public void accept(TreeVisitor visitor)
-
-