Class FunctionDeclarationTreeImpl
- java.lang.Object
-
- org.sonar.php.tree.impl.PHPTree
-
- org.sonar.php.tree.impl.declaration.FunctionDeclarationTreeImpl
-
- All Implemented Interfaces:
HasFunctionSymbol
,FunctionDeclarationTree
,FunctionTree
,HasAttributes
,StatementTree
,Tree
public class FunctionDeclarationTreeImpl extends PHPTree implements FunctionDeclarationTree, HasFunctionSymbol
-
-
Constructor Summary
Constructors Constructor Description FunctionDeclarationTreeImpl(List<AttributeGroupTree> attributeGroups, InternalSyntaxToken functionToken, InternalSyntaxToken referenceToken, NameIdentifierTree name, ParameterListTree parameters, ReturnTypeClauseTree returnTypeClause, BlockTree body)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
accept(VisitorCheck visitor)
List<AttributeGroupTree>
attributeGroups()
BlockTree
body()
Iterator<Tree>
childrenIterator()
Creates iterator for children of this node.SyntaxToken
functionToken()
Tree.Kind
getKind()
NameIdentifierTree
name()
ParameterListTree
parameters()
SyntaxToken
referenceToken()
ReturnTypeClauseTree
returnTypeClause()
void
setSymbol(FunctionSymbol symbol)
FunctionSymbol
symbol()
-
Methods inherited from class org.sonar.php.tree.impl.PHPTree
getFirstToken, getLastToken, getLine, getParent, is, isLeaf, setParent, toString
-
-
-
-
Constructor Detail
-
FunctionDeclarationTreeImpl
public FunctionDeclarationTreeImpl(List<AttributeGroupTree> attributeGroups, InternalSyntaxToken functionToken, @Nullable InternalSyntaxToken referenceToken, NameIdentifierTree name, ParameterListTree parameters, @Nullable ReturnTypeClauseTree returnTypeClause, BlockTree body)
-
-
Method Detail
-
attributeGroups
public List<AttributeGroupTree> attributeGroups()
- Specified by:
attributeGroups
in interfaceHasAttributes
-
functionToken
public SyntaxToken functionToken()
- Specified by:
functionToken
in interfaceFunctionDeclarationTree
- Specified by:
functionToken
in interfaceFunctionTree
-
referenceToken
@Nullable public SyntaxToken referenceToken()
- Specified by:
referenceToken
in interfaceFunctionDeclarationTree
- Specified by:
referenceToken
in interfaceFunctionTree
-
name
public NameIdentifierTree name()
- Specified by:
name
in interfaceFunctionDeclarationTree
-
parameters
public ParameterListTree parameters()
- Specified by:
parameters
in interfaceFunctionDeclarationTree
- Specified by:
parameters
in interfaceFunctionTree
-
returnTypeClause
@Nullable public ReturnTypeClauseTree returnTypeClause()
- Specified by:
returnTypeClause
in interfaceFunctionDeclarationTree
- Specified by:
returnTypeClause
in interfaceFunctionTree
-
body
public BlockTree body()
- Specified by:
body
in interfaceFunctionDeclarationTree
- Specified by:
body
in interfaceFunctionTree
-
childrenIterator
public Iterator<Tree> childrenIterator()
Description copied from class:PHPTree
Creates iterator for children of this node. Note that iterator may containnull
elements.- Specified by:
childrenIterator
in classPHPTree
-
accept
public void accept(VisitorCheck visitor)
-
symbol
public FunctionSymbol symbol()
- Specified by:
symbol
in interfaceHasFunctionSymbol
-
setSymbol
public void setSymbol(FunctionSymbol symbol)
- Specified by:
setSymbol
in interfaceHasFunctionSymbol
-
-