Package org.sonar.python.tree
Class ForStatementImpl
- java.lang.Object
-
- org.sonar.python.tree.PyTree
-
- org.sonar.python.tree.ForStatementImpl
-
- All Implemented Interfaces:
ForStatement,Statement,Tree
public class ForStatementImpl extends PyTree implements ForStatement
-
-
Constructor Summary
Constructors Constructor Description ForStatementImpl(com.sonar.sslr.api.AstNode astNode, Token forKeyword, List<Expression> expressions, Token inKeyword, List<Expression> testExpressions, Token colon, StatementList body, Token elseKeyword, Token elseColon, StatementList elseBody, Token asyncKeyword)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaccept(TreeVisitor visitor)TokenasyncKeyword()StatementListbody()List<Tree>children()Tokencolon()StatementListelseBody()TokenelseColon()TokenelseKeyword()List<Expression>expressions()TokenforKeyword()Tree.KindgetKind()TokeninKeyword()booleanisAsync()List<Expression>testExpressions()-
Methods inherited from class org.sonar.python.tree.PyTree
astNode, firstToken, is, lastToken, parent, setParent
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.sonar.python.api.tree.Tree
ancestors, astNode, descendants, descendants, firstToken, is, lastToken, parent
-
-
-
-
Constructor Detail
-
ForStatementImpl
public ForStatementImpl(com.sonar.sslr.api.AstNode astNode, Token forKeyword, List<Expression> expressions, Token inKeyword, List<Expression> testExpressions, Token colon, StatementList body, @Nullable Token elseKeyword, @Nullable Token elseColon, @Nullable StatementList elseBody, @Nullable Token asyncKeyword)
-
-
Method Detail
-
accept
public void accept(TreeVisitor visitor)
-
forKeyword
public Token forKeyword()
- Specified by:
forKeywordin interfaceForStatement
-
expressions
public List<Expression> expressions()
- Specified by:
expressionsin interfaceForStatement
-
inKeyword
public Token inKeyword()
- Specified by:
inKeywordin interfaceForStatement
-
testExpressions
public List<Expression> testExpressions()
- Specified by:
testExpressionsin interfaceForStatement
-
colon
public Token colon()
- Specified by:
colonin interfaceForStatement
-
body
public StatementList body()
- Specified by:
bodyin interfaceForStatement
-
elseKeyword
@CheckForNull public Token elseKeyword()
- Specified by:
elseKeywordin interfaceForStatement
-
elseColon
@CheckForNull public Token elseColon()
- Specified by:
elseColonin interfaceForStatement
-
elseBody
@CheckForNull public StatementList elseBody()
- Specified by:
elseBodyin interfaceForStatement
-
isAsync
public boolean isAsync()
- Specified by:
isAsyncin interfaceForStatement
-
asyncKeyword
@CheckForNull public Token asyncKeyword()
- Specified by:
asyncKeywordin interfaceForStatement
-
-