original_string: private function getMethod(\ReflectionMethod $method)
      {
          $methodStmt = $this->factory->method($method->name);
          $params = $method->getParameters();
          foreach ($params as $param) {
              $methodStmt = $this->getMethodStatement($param, $methodStmt);
          }
          $returnType = $method->getReturnType();
          if ($returnType instanceof \ReflectionType) {
              $this->setReturnType($returnType, $methodStmt);
          }
          $methodInsideStatements = $this->getMethodInsideStatement($method);
          $methodStmt->addStmts($methodInsideStatements);
  
          return $this->addMethodDocComment($methodStmt, $method);
      }
code: private function getMethod(\ReflectionMethod $method)
      {
          $methodStmt = $this->factory->method($method->name);
          $params = $method->getParameters();
          foreach ($params as $param) {
              $methodStmt = $this->getMethodStatement($param, $methodStmt);
          }
          $returnType = $method->getReturnType();
          if ($returnType instanceof \ReflectionType) {
              $this->setReturnType($returnType, $methodStmt);
          }
          $methodInsideStatements = $this->getMethodInsideStatement($method);
          $methodStmt->addStmts($methodInsideStatements);
  
          return $this->addMethodDocComment($methodStmt, $method);
      }
code_tokens: private function getMethod ( \ ReflectionMethod $ method ) { $ methodStmt = $ this -> factory -> method ( $ method -> name ) ; $ params = $ method -> getParameters ( ) ; foreach ( $ params as $ param ) { $ methodStmt = $ this -> getMethodStatement ( $ param , $ methodStmt ) ; } $ returnType = $ method -> getReturnType ( ) ; if ( $ returnType instanceof \ ReflectionType ) { $ this -> setReturnType ( $ returnType , $ methodStmt ) ; } $ methodInsideStatements = $ this -> getMethodInsideStatement ( $ method ) ; $ methodStmt -> addStmts ( $ methodInsideStatements ) ; return $ this -> addMethodDocComment ( $ methodStmt , $ method ) ; }
docstring: Return method statement
  
  @return \PhpParser\Node\Stmt\ClassMethod
docstring_tokens: Return method statement