getStmts() public méthode

The function body
public getStmts ( ) : PhpParser\Node\Stmt[]
Résultat PhpParser\Node\Stmt[]
 private function getVariableAccesses(FunctionLike $function) : array
 {
     $traverser = new NodeTraverser();
     $accessLocator = new VariableAccessLocatorVisitor();
     $traverser->addVisitor(new FunctionScopeIsolatingVisitor($accessLocator));
     $traverser->traverse([$function->getStmts()]);
     return $accessLocator->getFoundVariableAccesses();
 }
 /**
  * {@inheritDoc}
  */
 public function isGenerator()
 {
     $nodeTraverser = new NodeTraverser(false);
     $nodeDetector = new GeneratorDetector();
     $nodeTraverser->addVisitor($nodeDetector);
     /* @see https://github.com/nikic/PHP-Parser/issues/235 */
     $nodeTraverser->traverse($this->functionLikeNode->getStmts() ?: array());
     return $nodeDetector->isGenerator();
 }