mirror of
https://github.com/rectorphp/rector.git
synced 2025-02-25 04:03:55 +01:00
22 lines
2.3 KiB
PHP
22 lines
2.3 KiB
PHP
<?php
|
|
|
|
declare (strict_types=1);
|
|
namespace RectorPrefix20210524;
|
|
|
|
use Rector\Core\ValueObject\Visibility;
|
|
use Rector\NetteToSymfony\Rector\MethodCall\WrapTransParameterNameRector;
|
|
use Rector\Renaming\Rector\MethodCall\RenameMethodRector;
|
|
use Rector\Renaming\Rector\Name\RenameClassRector;
|
|
use Rector\Renaming\ValueObject\MethodCallRename;
|
|
use Rector\Visibility\Rector\ClassMethod\ChangeMethodVisibilityRector;
|
|
use Rector\Visibility\ValueObject\ChangeMethodVisibility;
|
|
use RectorPrefix20210524\Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;
|
|
use Symplify\SymfonyPhpConfig\ValueObjectInliner;
|
|
return static function (\RectorPrefix20210524\Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator $containerConfigurator) : void {
|
|
$services = $containerConfigurator->services();
|
|
$services->set(\Rector\Visibility\Rector\ClassMethod\ChangeMethodVisibilityRector::class)->call('configure', [[\Rector\Visibility\Rector\ClassMethod\ChangeMethodVisibilityRector::METHOD_VISIBILITIES => \Symplify\SymfonyPhpConfig\ValueObjectInliner::inline([new \Rector\Visibility\ValueObject\ChangeMethodVisibility('Kdyby\\Events\\Subscriber', 'getSubscribedEvents', \Rector\Core\ValueObject\Visibility::STATIC)])]]);
|
|
$services->set(\Rector\Renaming\Rector\MethodCall\RenameMethodRector::class)->call('configure', [[\Rector\Renaming\Rector\MethodCall\RenameMethodRector::METHOD_CALL_RENAMES => \Symplify\SymfonyPhpConfig\ValueObjectInliner::inline([new \Rector\Renaming\ValueObject\MethodCallRename('Kdyby\\Translation\\Translator', 'translate', 'trans'), new \Rector\Renaming\ValueObject\MethodCallRename('Kdyby\\RabbitMq\\IConsumer', 'process', 'execute')])]]);
|
|
$services->set(\Rector\Renaming\Rector\Name\RenameClassRector::class)->call('configure', [[\Rector\Renaming\Rector\Name\RenameClassRector::OLD_TO_NEW_CLASSES => ['Kdyby\\RabbitMq\\IConsumer' => 'OldSound\\RabbitMqBundle\\RabbitMq\\ConsumerInterface', 'Kdyby\\RabbitMq\\IProducer' => 'OldSound\\RabbitMqBundle\\RabbitMq\\ProducerInterface', 'Kdyby\\Monolog\\Logger' => 'Psr\\Log\\LoggerInterface', 'Kdyby\\Events\\Subscriber' => 'Symfony\\Component\\EventDispatcher\\EventSubscriberInterface', 'Kdyby\\Translation\\Translator' => 'Symfony\\Contracts\\Translation\\TranslatorInterface']]]);
|
|
$services->set(\Rector\NetteToSymfony\Rector\MethodCall\WrapTransParameterNameRector::class);
|
|
};
|