Tomas Votruba cdc3b7adef Updated Rector to commit f451b0b8e1e6761ec7f50809745d44d01caba66d
f451b0b8e1 [PHP 8.0] Bump to promoted properties (#4)
2021-05-10 23:39:21 +00:00

25 lines
756 B
PHP

<?php
declare (strict_types=1);
namespace Rector\RemovingStatic\NodeFactory;
use PhpParser\Node\Stmt\Expression;
use Rector\Core\PhpParser\Node\NodeFactory;
use Rector\Core\ValueObject\MethodName;
final class SetUpFactory
{
/**
* @var \Rector\Core\PhpParser\Node\NodeFactory
*/
private $nodeFactory;
public function __construct(\Rector\Core\PhpParser\Node\NodeFactory $nodeFactory)
{
$this->nodeFactory = $nodeFactory;
}
public function createParentStaticCall() : \PhpParser\Node\Stmt\Expression
{
$parentSetupStaticCall = $this->nodeFactory->createStaticCall('parent', \Rector\Core\ValueObject\MethodName::SET_UP);
return new \PhpParser\Node\Stmt\Expression($parentSetupStaticCall);
}
}