mirror of
https://github.com/rectorphp/rector.git
synced 2025-01-18 05:48:21 +01:00
Updated Rector to commit 9f98873278a129166bfe7b65829d09f5de76d679
9f98873278
[DX] Remove deprecated constants (#1833)
This commit is contained in:
parent
7964c1b773
commit
bf1ce866f1
@ -31,11 +31,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class ArgumentAdderRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const ADDED_ARGUMENTS = 'added_arguments';
|
||||
/**
|
||||
* @var ArgumentAdder[]
|
||||
*/
|
||||
@ -118,9 +113,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$addedArguments = $configuration[self::ADDED_ARGUMENTS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($addedArguments, \Rector\Arguments\ValueObject\ArgumentAdder::class);
|
||||
$this->addedArguments = $addedArguments;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Arguments\ValueObject\ArgumentAdder::class);
|
||||
$this->addedArguments = $configuration;
|
||||
}
|
||||
/**
|
||||
* @param \PhpParser\Node\Expr\MethodCall|\PhpParser\Node\Expr\StaticCall|\PhpParser\Node\Stmt\ClassMethod $node
|
||||
|
@ -19,11 +19,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class ReplaceArgumentDefaultValueRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const REPLACED_ARGUMENTS = 'replaced_arguments';
|
||||
/**
|
||||
* @var ReplaceArgumentDefaultValue[]
|
||||
*/
|
||||
@ -85,9 +80,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$replacedArguments = $configuration[self::REPLACED_ARGUMENTS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($replacedArguments);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($replacedArguments, \Rector\Arguments\ValueObject\ReplaceArgumentDefaultValue::class);
|
||||
$this->replacedArguments = $replacedArguments;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Arguments\ValueObject\ReplaceArgumentDefaultValue::class);
|
||||
$this->replacedArguments = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -20,11 +20,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class FunctionArgumentDefaultValueReplacerRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const REPLACED_ARGUMENTS = 'replaced_arguments';
|
||||
/**
|
||||
* @var ReplaceFuncCallArgumentDefaultValue[]
|
||||
*/
|
||||
@ -81,8 +76,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$replacedArguments = $configuration[self::REPLACED_ARGUMENTS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($replacedArguments, \Rector\Arguments\ValueObject\ReplaceFuncCallArgumentDefaultValue::class);
|
||||
$this->replacedArguments = $replacedArguments;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Arguments\ValueObject\ReplaceFuncCallArgumentDefaultValue::class);
|
||||
$this->replacedArguments = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -17,11 +17,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class SwapFuncCallArgumentsRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const FUNCTION_ARGUMENT_SWAPS = 'new_argument_positions_by_function_name';
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
@ -89,9 +84,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$functionArgumentSwaps = $configuration[self::FUNCTION_ARGUMENT_SWAPS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($functionArgumentSwaps, \Rector\Arguments\ValueObject\SwapFuncCallArguments::class);
|
||||
$this->functionArgumentSwaps = $functionArgumentSwaps;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Arguments\ValueObject\SwapFuncCallArguments::class);
|
||||
$this->functionArgumentSwaps = $configuration;
|
||||
}
|
||||
/**
|
||||
* @return array<int, Node\Arg>
|
||||
|
@ -23,11 +23,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class MoveServicesBySuffixToDirectoryRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const GROUP_NAMES_BY_SUFFIX = 'group_names_by_suffix';
|
||||
/**
|
||||
* @var string[]
|
||||
*/
|
||||
@ -89,10 +84,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$groupNamesBySuffix = $configuration[self::GROUP_NAMES_BY_SUFFIX] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($groupNamesBySuffix);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($groupNamesBySuffix);
|
||||
$this->groupNamesBySuffix = $groupNamesBySuffix;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
$this->groupNamesBySuffix = $configuration;
|
||||
}
|
||||
/**
|
||||
* A. Match classes by suffix and move them to group namespace
|
||||
|
@ -22,11 +22,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class OrderAttributesRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const ATTRIBUTES_ORDER = 'attributes_order';
|
||||
/**
|
||||
* @var array<string, int>
|
||||
*/
|
||||
@ -82,10 +77,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$attributesOrder = $configuration[self::ATTRIBUTES_ORDER] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($attributesOrder);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($attributesOrder);
|
||||
$this->attributesOrderByName = \array_flip($attributesOrder);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
$this->attributesOrderByName = \array_flip($configuration);
|
||||
}
|
||||
private function resolveAttributeGroupPosition(\PhpParser\Node\AttributeGroup $attributeGroup) : int
|
||||
{
|
||||
|
@ -27,11 +27,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class ReturnArrayClassMethodToYieldRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const METHODS_TO_YIELDS = 'methods_to_yields';
|
||||
/**
|
||||
* @var ReturnArrayClassMethodToyield[]
|
||||
*/
|
||||
@ -115,9 +110,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$methodsToYields = $configuration[self::METHODS_TO_YIELDS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($methodsToYields, \Rector\CodingStyle\ValueObject\ReturnArrayClassMethodToYield::class);
|
||||
$this->methodsToYields = $methodsToYields;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\CodingStyle\ValueObject\ReturnArrayClassMethodToYield::class);
|
||||
$this->methodsToYields = $configuration;
|
||||
}
|
||||
private function collectReturnArrayNodesFromClassMethod(\PhpParser\Node\Stmt\ClassMethod $classMethod) : ?\PhpParser\Node\Expr\Array_
|
||||
{
|
||||
|
@ -21,12 +21,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class PreferThisOrSelfMethodCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @api
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const TYPE_TO_PREFERENCE = 'type_to_preference';
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
@ -99,11 +93,9 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$typeToPreference = $configuration[self::TYPE_TO_PREFERENCE] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($typeToPreference);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($typeToPreference));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($typeToPreference, \Rector\CodingStyle\Enum\PreferenceSelfThis::class);
|
||||
$this->typeToPreference = $typeToPreference;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($configuration));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\CodingStyle\Enum\PreferenceSelfThis::class);
|
||||
$this->typeToPreference = $configuration;
|
||||
}
|
||||
/**
|
||||
* @param \PhpParser\Node\Expr\MethodCall|\PhpParser\Node\Expr\StaticCall $node
|
||||
|
@ -15,11 +15,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class AddPackageToRequireComposerRector implements \Rector\Composer\Contract\Rector\ComposerRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const PACKAGES_AND_VERSIONS = 'packages_and_versions';
|
||||
/**
|
||||
* @var PackageAndVersion[]
|
||||
*/
|
||||
@ -59,9 +54,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$packagesAndVersions = $configuration[self::PACKAGES_AND_VERSIONS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($packagesAndVersions, \Rector\Composer\ValueObject\PackageAndVersion::class);
|
||||
$this->versionGuard->validate($packagesAndVersions);
|
||||
$this->packagesAndVersions = $packagesAndVersions;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Composer\ValueObject\PackageAndVersion::class);
|
||||
$this->versionGuard->validate($configuration);
|
||||
$this->packagesAndVersions = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -15,11 +15,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class AddPackageToRequireDevComposerRector implements \Rector\Composer\Contract\Rector\ComposerRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const PACKAGES_AND_VERSIONS = 'packages_and_version';
|
||||
/**
|
||||
* @var PackageAndVersion[]
|
||||
*/
|
||||
@ -59,9 +54,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$packagesAndVersions = $configuration[self::PACKAGES_AND_VERSIONS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($packagesAndVersions, \Rector\Composer\ValueObject\PackageAndVersion::class);
|
||||
$this->versionGuard->validate($packagesAndVersions);
|
||||
$this->packageAndVersions = $packagesAndVersions;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Composer\ValueObject\PackageAndVersion::class);
|
||||
$this->versionGuard->validate($configuration);
|
||||
$this->packageAndVersions = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -15,11 +15,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class ChangePackageVersionComposerRector implements \Rector\Composer\Contract\Rector\ComposerRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const PACKAGES_AND_VERSIONS = 'packages_and_versions';
|
||||
/**
|
||||
* @var PackageAndVersion[]
|
||||
*/
|
||||
@ -62,9 +57,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$packagesAndVersions = $configuration[self::PACKAGES_AND_VERSIONS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($packagesAndVersions, \Rector\Composer\ValueObject\PackageAndVersion::class);
|
||||
$this->versionGuard->validate($packagesAndVersions);
|
||||
$this->packagesAndVersions = $packagesAndVersions;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Composer\ValueObject\PackageAndVersion::class);
|
||||
$this->versionGuard->validate($configuration);
|
||||
$this->packagesAndVersions = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -13,11 +13,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RemovePackageComposerRector implements \Rector\Composer\Contract\Rector\ComposerRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const PACKAGE_NAMES = 'package_names';
|
||||
/**
|
||||
* @var string[]
|
||||
*/
|
||||
@ -48,9 +43,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$packagesNames = $configuration[self::PACKAGE_NAMES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($packagesNames);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($packagesNames);
|
||||
$this->packageNames = $packagesNames;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
$this->packageNames = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -14,11 +14,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RenamePackageComposerRector implements \Rector\Composer\Contract\Rector\ComposerRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const RENAME_PACKAGES = 'rename_packages';
|
||||
/**
|
||||
* @var RenamePackage[]
|
||||
*/
|
||||
@ -59,8 +54,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$renamePackages = $configuration[self::RENAME_PACKAGES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($renamePackages, \Rector\Composer\ValueObject\RenamePackage::class);
|
||||
$this->renamePackages = $renamePackages;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Composer\ValueObject\RenamePackage::class);
|
||||
$this->renamePackages = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -15,11 +15,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class ReplacePackageAndVersionComposerRector implements \Rector\Composer\Contract\Rector\ComposerRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const REPLACE_PACKAGES_AND_VERSIONS = 'replace_packages_and_versions';
|
||||
/**
|
||||
* @var ReplacePackageAndVersion[]
|
||||
*/
|
||||
@ -62,9 +57,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$replacePackagesAndVersions = $configuration[self::REPLACE_PACKAGES_AND_VERSIONS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($replacePackagesAndVersions, \Rector\Composer\ValueObject\ReplacePackageAndVersion::class);
|
||||
$this->versionGuard->validate($replacePackagesAndVersions);
|
||||
$this->replacePackagesAndVersions = $replacePackagesAndVersions;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Composer\ValueObject\ReplacePackageAndVersion::class);
|
||||
$this->versionGuard->validate($configuration);
|
||||
$this->replacePackagesAndVersions = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -21,11 +21,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RemoveAnnotationRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const ANNOTATIONS_TO_REMOVE = 'annotations_to_remove';
|
||||
/**
|
||||
* @var string[]
|
||||
*/
|
||||
@ -90,9 +85,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$annotationsToRemove = $configuration[self::ANNOTATIONS_TO_REMOVE] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($annotationsToRemove);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($annotationsToRemove);
|
||||
$this->annotationsToRemove = $annotationsToRemove;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
$this->annotationsToRemove = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -23,11 +23,6 @@ use Symplify\RuleDocGenerator\ValueObject\RuleDefinition;
|
||||
*/
|
||||
final class RemovePhpVersionIdCheckRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const PHP_VERSION_CONSTRAINT = 'phpVersionConstraint';
|
||||
/**
|
||||
* @var int|string|null
|
||||
*/
|
||||
@ -46,11 +41,10 @@ final class RemovePhpVersionIdCheckRector extends \Rector\Core\Rector\AbstractRe
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$this->phpVersionConstraint = $configuration[self::PHP_VERSION_CONSTRAINT] ?? null;
|
||||
$this->phpVersionConstraint = \array_pop($configuration);
|
||||
}
|
||||
public function getRuleDefinition() : \Symplify\RuleDocGenerator\ValueObject\RuleDefinition
|
||||
{
|
||||
$exampleConfiguration = [self::PHP_VERSION_CONSTRAINT => \Rector\Core\ValueObject\PhpVersion::PHP_80];
|
||||
return new \Symplify\RuleDocGenerator\ValueObject\RuleDefinition('Remove unneeded PHP_VERSION_ID check', [new \Symplify\RuleDocGenerator\ValueObject\CodeSample\ConfiguredCodeSample(<<<'CODE_SAMPLE'
|
||||
class SomeClass
|
||||
{
|
||||
@ -72,7 +66,7 @@ class SomeClass
|
||||
}
|
||||
}
|
||||
CODE_SAMPLE
|
||||
, $exampleConfiguration)]);
|
||||
, [\Rector\Core\ValueObject\PhpVersion::PHP_80])]);
|
||||
}
|
||||
/**
|
||||
* @return array<class-string<Node>>
|
||||
|
@ -21,11 +21,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class AddMethodParentCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const METHODS_BY_PARENT_TYPES = 'methods_by_parent_type';
|
||||
/**
|
||||
* @var array<string, string>
|
||||
*/
|
||||
@ -92,11 +87,10 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$methodsByParentTypes = $configuration[self::METHODS_BY_PARENT_TYPES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($methodsByParentTypes));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($methodsByParentTypes);
|
||||
/** @var array<string, string> $methodsByParentTypes */
|
||||
$this->methodByParentTypes = $methodsByParentTypes;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($configuration));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
/** @var array<string, string> $configuration */
|
||||
$this->methodByParentTypes = $configuration;
|
||||
}
|
||||
private function shouldSkipMethod(\PhpParser\Node\Stmt\ClassMethod $classMethod, string $method) : bool
|
||||
{
|
||||
|
@ -27,11 +27,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class DowngradeAttributeToAnnotationRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const ATTRIBUTE_TO_ANNOTATION = 'attribute_to_annotation';
|
||||
/**
|
||||
* @var DowngradeAttributeToAnnotation[]
|
||||
*/
|
||||
@ -110,9 +105,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$attributesToAnnotations = $configuration[self::ATTRIBUTE_TO_ANNOTATION] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($attributesToAnnotations, \Rector\DowngradePhp80\ValueObject\DowngradeAttributeToAnnotation::class);
|
||||
$this->attributesToAnnotations = $attributesToAnnotations;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\DowngradePhp80\ValueObject\DowngradeAttributeToAnnotation::class);
|
||||
$this->attributesToAnnotations = $configuration;
|
||||
}
|
||||
/**
|
||||
* @param \PhpParser\Node\Param|\PhpParser\Node\Stmt\Class_|\PhpParser\Node\Stmt\ClassMethod|\PhpParser\Node\Stmt\Function_|\PhpParser\Node\Stmt\Interface_|\PhpParser\Node\Stmt\Property $node
|
||||
|
@ -26,12 +26,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class StringClassNameToClassConstantRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\AllowEmptyConfigurableRectorInterface, \Rector\VersionBonding\Contract\MinPhpVersionInterface
|
||||
{
|
||||
/**
|
||||
* @api
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const CLASSES_TO_SKIP = 'classes_to_skip';
|
||||
/**
|
||||
* @var string[]
|
||||
*/
|
||||
@ -108,10 +102,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$classesToSkip = $configuration[self::CLASSES_TO_SKIP] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($classesToSkip);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($classesToSkip);
|
||||
$this->classesToSkip = $classesToSkip;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
$this->classesToSkip = $configuration;
|
||||
}
|
||||
public function provideMinPhpVersion() : int
|
||||
{
|
||||
|
@ -22,11 +22,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class ReservedObjectRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface, \Rector\VersionBonding\Contract\MinPhpVersionInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const RESERVED_KEYWORDS_TO_REPLACEMENTS = 'reserved_keywords_to_replacements';
|
||||
/**
|
||||
* @var array<string, string>
|
||||
*/
|
||||
@ -71,11 +66,9 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$reservedKeywordsToReplacements = $configuration[self::RESERVED_KEYWORDS_TO_REPLACEMENTS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($reservedKeywordsToReplacements);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($reservedKeywordsToReplacements));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($reservedKeywordsToReplacements);
|
||||
$this->reservedKeywordsToReplacements = $reservedKeywordsToReplacements;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($configuration));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
$this->reservedKeywordsToReplacements = $configuration;
|
||||
}
|
||||
private function processIdentifier(\PhpParser\Node\Identifier $identifier) : \PhpParser\Node\Identifier
|
||||
{
|
||||
|
@ -40,11 +40,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class AnnotationToAttributeRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface, \Rector\VersionBonding\Contract\MinPhpVersionInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const ANNOTATION_TO_ATTRIBUTE = 'annotations_to_attributes';
|
||||
/**
|
||||
* @var AnnotationToAttribute[]
|
||||
*/
|
||||
@ -148,11 +143,10 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$annotationsToAttributes = $configuration[self::ANNOTATION_TO_ATTRIBUTE] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($annotationsToAttributes, \Rector\Php80\ValueObject\AnnotationToAttribute::class);
|
||||
$this->annotationsToAttributes = $annotationsToAttributes;
|
||||
$this->unwrapableAnnotationAnalyzer->configure($annotationsToAttributes);
|
||||
$this->removableAnnotationAnalyzer->configure($annotationsToAttributes);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Php80\ValueObject\AnnotationToAttribute::class);
|
||||
$this->annotationsToAttributes = $configuration;
|
||||
$this->unwrapableAnnotationAnalyzer->configure($configuration);
|
||||
$this->removableAnnotationAnalyzer->configure($configuration);
|
||||
}
|
||||
public function provideMinPhpVersion() : int
|
||||
{
|
||||
|
@ -13,16 +13,12 @@ use Rector\Privatization\NodeFactory\ClassConstantFetchValueFactory;
|
||||
use Rector\Privatization\ValueObject\ReplaceStringWithClassConstant;
|
||||
use Symplify\RuleDocGenerator\ValueObject\CodeSample\ConfiguredCodeSample;
|
||||
use Symplify\RuleDocGenerator\ValueObject\RuleDefinition;
|
||||
use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
/**
|
||||
* @see \Rector\Tests\Privatization\Rector\MethodCall\ReplaceStringWithClassConstantRector\ReplaceStringWithClassConstantRectorTest
|
||||
*/
|
||||
final class ReplaceStringWithClassConstantRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const REPLACE_STRING_WITH_CLASS_CONSTANT = 'replace_string_with_class_constant';
|
||||
/**
|
||||
* @var ReplaceStringWithClassConstant[]
|
||||
*/
|
||||
@ -96,7 +92,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$this->replaceStringWithClassConstants = $configuration[self::REPLACE_STRING_WITH_CLASS_CONSTANT] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Privatization\ValueObject\ReplaceStringWithClassConstant::class);
|
||||
$this->replaceStringWithClassConstants = $configuration;
|
||||
}
|
||||
private function matchArg(\PhpParser\Node\Expr\MethodCall $methodCall, \Rector\Privatization\ValueObject\ReplaceStringWithClassConstant $replaceStringWithClassConstant) : ?\PhpParser\Node\Arg
|
||||
{
|
||||
|
@ -20,11 +20,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class ArgumentRemoverRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const REMOVED_ARGUMENTS = 'removed_arguments';
|
||||
/**
|
||||
* @var ArgumentRemover[]
|
||||
*/
|
||||
@ -70,9 +65,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$removedArguments = $configuration[self::REMOVED_ARGUMENTS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($removedArguments, \Rector\Removing\ValueObject\ArgumentRemover::class);
|
||||
$this->removedArguments = $removedArguments;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Removing\ValueObject\ArgumentRemover::class);
|
||||
$this->removedArguments = $configuration;
|
||||
}
|
||||
/**
|
||||
* @param \PhpParser\Node\Expr\MethodCall|\PhpParser\Node\Expr\StaticCall|\PhpParser\Node\Stmt\ClassMethod $node
|
||||
|
@ -15,11 +15,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RemoveInterfacesRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const INTERFACES_TO_REMOVE = 'interfaces_to_remove';
|
||||
/**
|
||||
* @var string[]
|
||||
*/
|
||||
@ -65,9 +60,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$interfacesToRemove = $configuration[self::INTERFACES_TO_REMOVE] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($interfacesToRemove);
|
||||
/** @var string[] $interfacesToRemove */
|
||||
$this->interfacesToRemove = $interfacesToRemove;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
/** @var string[] $configuration */
|
||||
$this->interfacesToRemove = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -18,12 +18,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RemoveParentRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @api
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const PARENT_TYPES_TO_REMOVE = 'parents_types_to_remove';
|
||||
/**
|
||||
* @var string[]
|
||||
*/
|
||||
@ -83,9 +77,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$parentTypesToRemove = $configuration[self::PARENT_TYPES_TO_REMOVE] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($parentTypesToRemove);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($parentTypesToRemove);
|
||||
$this->parentClassesToRemove = $parentTypesToRemove;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
$this->parentClassesToRemove = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -17,11 +17,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RemoveTraitUseRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const TRAITS_TO_REMOVE = 'traits_to_remove';
|
||||
/**
|
||||
* @var bool
|
||||
*/
|
||||
@ -79,9 +74,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$traitsToRemove = $configuration[self::TRAITS_TO_REMOVE] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($traitsToRemove);
|
||||
/** @var string[] $traitsToRemove */
|
||||
$this->traitsToRemove = $traitsToRemove;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
$this->traitsToRemove = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -17,11 +17,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RemoveFuncCallArgRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const REMOVED_FUNCTION_ARGUMENTS = 'removed_function_arguments';
|
||||
/**
|
||||
* @var RemoveFuncCallArg[]
|
||||
*/
|
||||
@ -69,8 +64,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$removedFunctionArguments = $configuration[self::REMOVED_FUNCTION_ARGUMENTS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($removedFunctionArguments, \Rector\Removing\ValueObject\RemoveFuncCallArg::class);
|
||||
$this->removedFunctionArguments = $removedFunctionArguments;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Removing\ValueObject\RemoveFuncCallArg::class);
|
||||
$this->removedFunctionArguments = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -18,12 +18,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RemoveFuncCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @api
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const REMOVE_FUNC_CALLS = 'remove_func_calls';
|
||||
/**
|
||||
* @var RemoveFuncCall[]
|
||||
*/
|
||||
@ -77,9 +71,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$removeFuncCalls = $configuration[self::REMOVE_FUNC_CALLS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($removeFuncCalls, \Rector\Removing\ValueObject\RemoveFuncCall::class);
|
||||
$this->removeFuncCalls = $removeFuncCalls;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Removing\ValueObject\RemoveFuncCall::class);
|
||||
$this->removeFuncCalls = $configuration;
|
||||
}
|
||||
private function refactorFuncCallsWithPositions(\PhpParser\Node\Expr\FuncCall $funcCall, \Rector\Removing\ValueObject\RemoveFuncCall $removeFuncCall) : void
|
||||
{
|
||||
|
@ -20,11 +20,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RenameClassConstFetchRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const CLASS_CONSTANT_RENAME = 'constant_rename';
|
||||
/**
|
||||
* @var RenameClassConstFetchInterface[]
|
||||
*/
|
||||
@ -73,9 +68,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$renameClassConstFetches = $configuration[self::CLASS_CONSTANT_RENAME] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($renameClassConstFetches, \Rector\Renaming\Contract\RenameClassConstFetchInterface::class);
|
||||
$this->renameClassConstFetches = $renameClassConstFetches;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Renaming\Contract\RenameClassConstFetchInterface::class);
|
||||
$this->renameClassConstFetches = $configuration;
|
||||
}
|
||||
private function createClassAndConstFetch(\Rector\Renaming\ValueObject\RenameClassAndConstFetch $renameClassAndConstFetch) : \PhpParser\Node\Expr\ClassConstFetch
|
||||
{
|
||||
|
@ -21,11 +21,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RenameAnnotationRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const RENAMED_ANNOTATIONS = 'renamed_annotations';
|
||||
/**
|
||||
* @var RenameAnnotationInterface[]
|
||||
*/
|
||||
@ -99,9 +94,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$renamedAnnotations = $configuration[self::RENAMED_ANNOTATIONS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($renamedAnnotations);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($renamedAnnotations, \Rector\Renaming\Contract\RenameAnnotationInterface::class);
|
||||
$this->renameAnnotations = $renamedAnnotations;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Renaming\Contract\RenameAnnotationInterface::class);
|
||||
$this->renameAnnotations = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -16,11 +16,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RenameConstantRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const OLD_TO_NEW_CONSTANTS = 'old_to_new_constants';
|
||||
/**
|
||||
* @var array<string, string>
|
||||
*/
|
||||
@ -73,10 +68,9 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$oldToNewConstants = $configuration[self::OLD_TO_NEW_CONSTANTS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($oldToNewConstants));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($oldToNewConstants);
|
||||
/** @var array<string, string> $oldToNewConstants */
|
||||
$this->oldToNewConstants = $oldToNewConstants;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($configuration));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
/** @var array<string, string> $configuration */
|
||||
$this->oldToNewConstants = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -27,11 +27,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class PseudoNamespaceToNamespaceRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const NAMESPACE_PREFIXES_WITH_EXCLUDED_CLASSES = 'namespace_prefixed_with_excluded_classes';
|
||||
/**
|
||||
* @see https://regex101.com/r/chvLgs/1/
|
||||
* @var string
|
||||
@ -103,9 +98,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$namespacePrefixesWithExcludedClasses = $configuration[self::NAMESPACE_PREFIXES_WITH_EXCLUDED_CLASSES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($namespacePrefixesWithExcludedClasses, \Rector\Renaming\ValueObject\PseudoNamespaceToNamespace::class);
|
||||
$this->pseudoNamespacesToNamespaces = $namespacePrefixesWithExcludedClasses;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Renaming\ValueObject\PseudoNamespaceToNamespace::class);
|
||||
$this->pseudoNamespacesToNamespaces = $configuration;
|
||||
}
|
||||
/**
|
||||
* @param Stmt[] $stmts
|
||||
|
@ -18,11 +18,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RenameFunctionRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const OLD_FUNCTION_TO_NEW_FUNCTION = 'old_function_to_new_function';
|
||||
/**
|
||||
* @var array<string, string>
|
||||
*/
|
||||
@ -62,11 +57,9 @@ final class RenameFunctionRector extends \Rector\Core\Rector\AbstractRector impl
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$oldFunctionToNewFunction = $configuration[self::OLD_FUNCTION_TO_NEW_FUNCTION] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($oldFunctionToNewFunction);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_values($oldFunctionToNewFunction));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($oldFunctionToNewFunction);
|
||||
$this->oldFunctionToNewFunction = $oldFunctionToNewFunction;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_values($configuration));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
$this->oldFunctionToNewFunction = $configuration;
|
||||
}
|
||||
private function createName(string $newFunction) : \PhpParser\Node\Name
|
||||
{
|
||||
|
@ -26,11 +26,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RenameMethodRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const METHOD_CALL_RENAMES = 'method_call_renames';
|
||||
/**
|
||||
* @var MethodCallRenameInterface[]
|
||||
*/
|
||||
@ -101,10 +96,9 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$methodCallRenames = $configuration[self::METHOD_CALL_RENAMES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($methodCallRenames, \Rector\Renaming\Contract\MethodCallRenameInterface::class);
|
||||
$this->methodCallRenames = $methodCallRenames;
|
||||
$this->methodCallRenameCollector->addMethodCallRenames($methodCallRenames);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Renaming\Contract\MethodCallRenameInterface::class);
|
||||
$this->methodCallRenames = $configuration;
|
||||
$this->methodCallRenameCollector->addMethodCallRenames($configuration);
|
||||
}
|
||||
/**
|
||||
* @param \PhpParser\Node\Expr\MethodCall|\PhpParser\Node\Expr\StaticCall|\PhpParser\Node\Stmt\ClassMethod $node
|
||||
|
@ -26,11 +26,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RenameClassRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const OLD_TO_NEW_CLASSES = 'old_to_new_classes';
|
||||
/**
|
||||
* @readonly
|
||||
* @var \Rector\Core\Configuration\RenamedClassesDataCollector
|
||||
@ -100,10 +95,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$oldToNewClasses = $configuration[self::OLD_TO_NEW_CLASSES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($oldToNewClasses);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($oldToNewClasses);
|
||||
$this->addOldToNewClasses($oldToNewClasses);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
$this->addOldToNewClasses($configuration);
|
||||
}
|
||||
/**
|
||||
* @param array<string, string> $oldToNewClasses
|
||||
|
@ -23,11 +23,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RenameNamespaceRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const OLD_TO_NEW_NAMESPACES = 'old_to_new_namespaces';
|
||||
/**
|
||||
* @var array<string, string>
|
||||
*/
|
||||
@ -101,11 +96,10 @@ final class RenameNamespaceRector extends \Rector\Core\Rector\AbstractRector imp
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$oldToNewNamespaces = $configuration[self::OLD_TO_NEW_NAMESPACES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($oldToNewNamespaces));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($oldToNewNamespaces);
|
||||
/** @var array<string, string> $oldToNewNamespaces */
|
||||
$this->oldToNewNamespaces = $oldToNewNamespaces;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($configuration));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
/** @var array<string, string> $configuration */
|
||||
$this->oldToNewNamespaces = $configuration;
|
||||
}
|
||||
private function processFullyQualified(\PhpParser\Node\Name $name, \Rector\Renaming\ValueObject\RenamedNamespace $renamedNamespace) : ?\PhpParser\Node\Name\FullyQualified
|
||||
{
|
||||
|
@ -23,11 +23,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RenamePropertyRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const RENAMED_PROPERTIES = 'old_to_new_property_by_types';
|
||||
/**
|
||||
* @var RenameProperty[]
|
||||
*/
|
||||
@ -58,9 +53,8 @@ final class RenamePropertyRector extends \Rector\Core\Rector\AbstractRector impl
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$renamedProperties = $configuration[self::RENAMED_PROPERTIES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($renamedProperties, \Rector\Renaming\ValueObject\RenameProperty::class);
|
||||
$this->renamedProperties = $renamedProperties;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Renaming\ValueObject\RenameProperty::class);
|
||||
$this->renamedProperties = $configuration;
|
||||
}
|
||||
private function processFromClassLike(\PhpParser\Node\Stmt\ClassLike $classLike) : \PhpParser\Node\Stmt\ClassLike
|
||||
{
|
||||
|
@ -18,11 +18,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RenameStaticMethodRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const OLD_TO_NEW_METHODS_BY_CLASSES = 'old_to_new_method_by_classes';
|
||||
/**
|
||||
* @var RenameStaticMethod[]
|
||||
*/
|
||||
@ -59,9 +54,8 @@ final class RenameStaticMethodRector extends \Rector\Core\Rector\AbstractRector
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$oldToNewMethodsByClasses = $configuration[self::OLD_TO_NEW_METHODS_BY_CLASSES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($oldToNewMethodsByClasses, \Rector\Renaming\ValueObject\RenameStaticMethod::class);
|
||||
$this->staticMethodRenames = $oldToNewMethodsByClasses;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Renaming\ValueObject\RenameStaticMethod::class);
|
||||
$this->staticMethodRenames = $configuration;
|
||||
}
|
||||
private function rename(\PhpParser\Node\Expr\StaticCall $staticCall, \Rector\Renaming\ValueObject\RenameStaticMethod $renameStaticMethod) : \PhpParser\Node\Expr\StaticCall
|
||||
{
|
||||
|
@ -17,11 +17,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class RenameStringRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const STRING_CHANGES = 'string_changes';
|
||||
/**
|
||||
* @var array<string, string>
|
||||
*/
|
||||
@ -73,10 +68,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$stringChanges = $configuration[self::STRING_CHANGES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($stringChanges);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($stringChanges));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($stringChanges);
|
||||
$this->stringChanges = $stringChanges;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($configuration));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
$this->stringChanges = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -21,12 +21,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class CompleteImportForPartialAnnotationRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @api
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const USE_IMPORTS_TO_RESTORE = '$useImportsToRestore';
|
||||
/**
|
||||
* @var CompleteImportForPartialAnnotation[]
|
||||
*/
|
||||
@ -86,10 +80,9 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$useImportsToRestore = $configuration[self::USE_IMPORTS_TO_RESTORE] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($useImportsToRestore, \Rector\Restoration\ValueObject\CompleteImportForPartialAnnotation::class);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Restoration\ValueObject\CompleteImportForPartialAnnotation::class);
|
||||
$default = [new \Rector\Restoration\ValueObject\CompleteImportForPartialAnnotation('Doctrine\\ORM\\Mapping', 'ORM'), new \Rector\Restoration\ValueObject\CompleteImportForPartialAnnotation('Symfony\\Component\\Validator\\Constraints', 'Assert'), new \Rector\Restoration\ValueObject\CompleteImportForPartialAnnotation('JMS\\Serializer\\Annotation', 'Serializer')];
|
||||
$this->useImportsToRestore = \array_merge($useImportsToRestore, $default);
|
||||
$this->useImportsToRestore = \array_merge($configuration, $default);
|
||||
}
|
||||
private function addImportToNamespaceIfMissing(\PhpParser\Node\Stmt\Namespace_ $namespace, \Rector\Restoration\ValueObject\CompleteImportForPartialAnnotation $completeImportForPartialAnnotation) : \PhpParser\Node\Stmt\Namespace_
|
||||
{
|
||||
|
@ -20,11 +20,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class DimFetchAssignToMethodCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const DIM_FETCH_ASSIGN_TO_METHOD_CALL = 'dim_fetch_assign_to_method_call';
|
||||
/**
|
||||
* @var DimFetchAssignToMethodCall[]
|
||||
*/
|
||||
@ -91,9 +86,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$dimFetchAssignToMethodCalls = $configuration[self::DIM_FETCH_ASSIGN_TO_METHOD_CALL] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($dimFetchAssignToMethodCalls, \Rector\Transform\ValueObject\DimFetchAssignToMethodCall::class);
|
||||
$this->dimFetchAssignToMethodCalls = $dimFetchAssignToMethodCalls;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\DimFetchAssignToMethodCall::class);
|
||||
$this->dimFetchAssignToMethodCalls = $configuration;
|
||||
}
|
||||
private function findDimFetchAssignToMethodCall(\PhpParser\Node\Expr\Assign $assign) : ?\Rector\Transform\ValueObject\DimFetchAssignToMethodCall
|
||||
{
|
||||
|
@ -24,11 +24,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class GetAndSetToMethodCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const TYPE_TO_METHOD_CALLS = 'type_to_method_calls';
|
||||
/**
|
||||
* @var GetAndSetToMethodCall[]
|
||||
*/
|
||||
@ -85,9 +80,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$getAndSetToMethodCalls = $configuration[self::TYPE_TO_METHOD_CALLS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($getAndSetToMethodCalls, \Rector\Transform\ValueObject\GetAndSetToMethodCall::class);
|
||||
$this->getAndSetToMethodCalls = $getAndSetToMethodCalls;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\GetAndSetToMethodCall::class);
|
||||
$this->getAndSetToMethodCalls = $configuration;
|
||||
}
|
||||
private function processMagicSet(\PhpParser\Node\Expr $expr, \PhpParser\Node\Expr\PropertyFetch $propertyFetch) : ?\PhpParser\Node
|
||||
{
|
||||
|
@ -18,11 +18,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class PropertyAssignToMethodCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const PROPERTY_ASSIGNS_TO_METHODS_CALLS = 'property_assigns_to_methods_calls';
|
||||
/**
|
||||
* @var PropertyAssignToMethodCall[]
|
||||
*/
|
||||
@ -73,8 +68,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$propertyAssignsToMethodCalls = $configuration[self::PROPERTY_ASSIGNS_TO_METHODS_CALLS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($propertyAssignsToMethodCalls, \Rector\Transform\ValueObject\PropertyAssignToMethodCall::class);
|
||||
$this->propertyAssignsToMethodCalls = $propertyAssignsToMethodCalls;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\PropertyAssignToMethodCall::class);
|
||||
$this->propertyAssignsToMethodCalls = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -19,11 +19,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class PropertyFetchToMethodCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const PROPERTIES_TO_METHOD_CALLS = 'properties_to_method_calls';
|
||||
/**
|
||||
* @var PropertyFetchToMethodCall[]
|
||||
*/
|
||||
@ -69,9 +64,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$propertiesToMethodCalls = $configuration[self::PROPERTIES_TO_METHOD_CALLS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($propertiesToMethodCalls, \Rector\Transform\ValueObject\PropertyFetchToMethodCall::class);
|
||||
$this->propertiesToMethodCalls = $propertiesToMethodCalls;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\PropertyFetchToMethodCall::class);
|
||||
$this->propertiesToMethodCalls = $configuration;
|
||||
}
|
||||
private function processSetter(\PhpParser\Node\Expr\Assign $assign) : ?\PhpParser\Node
|
||||
{
|
||||
|
@ -19,11 +19,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class AttributeKeyToClassConstFetchRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const ATTRIBUTE_KEYS_TO_CLASS_CONST_FETCHES = 'attribute_keys_to_class_const_fetches';
|
||||
/**
|
||||
* @var AttributeKeyToClassConstFetch[]
|
||||
*/
|
||||
@ -91,8 +86,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$attributeKeysToClassConstFetches = $configuration[self::ATTRIBUTE_KEYS_TO_CLASS_CONST_FETCHES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($attributeKeysToClassConstFetches, \Rector\Transform\ValueObject\AttributeKeyToClassConstFetch::class);
|
||||
$this->attributeKeysToClassConstFetches = $attributeKeysToClassConstFetches;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\AttributeKeyToClassConstFetch::class);
|
||||
$this->attributeKeysToClassConstFetches = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -19,11 +19,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class WrapReturnRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const TYPE_METHOD_WRAPS = 'type_method_wraps';
|
||||
/**
|
||||
* @var WrapReturn[]
|
||||
*/
|
||||
@ -81,9 +76,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$typeMethodWraps = $configuration[self::TYPE_METHOD_WRAPS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($typeMethodWraps, \Rector\Transform\ValueObject\WrapReturn::class);
|
||||
$this->typeMethodWraps = $typeMethodWraps;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\WrapReturn::class);
|
||||
$this->typeMethodWraps = $configuration;
|
||||
}
|
||||
private function wrap(\PhpParser\Node\Stmt\ClassMethod $classMethod, bool $isArrayWrap) : ?\PhpParser\Node\Stmt\ClassMethod
|
||||
{
|
||||
|
@ -19,11 +19,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class AddInterfaceByParentRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const INTERFACE_BY_PARENT = 'interface_by_parent';
|
||||
/**
|
||||
* @var array<string, string>
|
||||
*/
|
||||
@ -84,10 +79,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$interfaceByParent = $configuration[self::INTERFACE_BY_PARENT] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($interfaceByParent);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($interfaceByParent));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($interfaceByParent);
|
||||
$this->interfaceByParent = $interfaceByParent;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($configuration));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
$this->interfaceByParent = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -19,11 +19,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class AddInterfaceByTraitRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const INTERFACE_BY_TRAIT = 'interface_by_trait';
|
||||
/**
|
||||
* @var array<string, string>
|
||||
*/
|
||||
@ -81,10 +76,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$interfaceByTrait = $configuration[self::INTERFACE_BY_TRAIT] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($interfaceByTrait);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($interfaceByTrait));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($interfaceByTrait);
|
||||
$this->interfaceByTrait = $interfaceByTrait;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($configuration));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
$this->interfaceByTrait = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -20,12 +20,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class MergeInterfacesRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @api
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const OLD_TO_NEW_INTERFACES = 'old_to_new_interfaces';
|
||||
/**
|
||||
* @var array<string, string>
|
||||
*/
|
||||
@ -75,11 +69,9 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$oldToNewInterfaces = $configuration[self::OLD_TO_NEW_INTERFACES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($oldToNewInterfaces);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($oldToNewInterfaces));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($oldToNewInterfaces);
|
||||
$this->oldToNewInterfaces = $oldToNewInterfaces;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($configuration));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
$this->oldToNewInterfaces = $configuration;
|
||||
}
|
||||
private function makeImplementsUnique(\PhpParser\Node\Stmt\Class_ $class) : void
|
||||
{
|
||||
|
@ -23,11 +23,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class ParentClassToTraitsRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const PARENT_CLASS_TO_TRAITS = 'parent_class_to_traits';
|
||||
/**
|
||||
* @var ParentClassToTraits[]
|
||||
*/
|
||||
@ -98,9 +93,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$parentClassToTraits = $configuration[self::PARENT_CLASS_TO_TRAITS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($parentClassToTraits, \Rector\Transform\ValueObject\ParentClassToTraits::class);
|
||||
$this->parentClassToTraits = $parentClassToTraits;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\ParentClassToTraits::class);
|
||||
$this->parentClassToTraits = $configuration;
|
||||
}
|
||||
private function removeParentClass(\PhpParser\Node\Stmt\Class_ $class) : void
|
||||
{
|
||||
|
@ -30,11 +30,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class ArgumentFuncCallToMethodCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const FUNCTIONS_TO_METHOD_CALLS = 'functions_to_method_calls';
|
||||
/**
|
||||
* @var ArgumentFuncCallToMethodCallInterface[]
|
||||
*/
|
||||
@ -129,10 +124,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$functionToMethodCalls = $configuration[self::FUNCTIONS_TO_METHOD_CALLS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($functionToMethodCalls);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($functionToMethodCalls, \Rector\Transform\Contract\ValueObject\ArgumentFuncCallToMethodCallInterface::class);
|
||||
$this->argumentFuncCallToMethodCalls = $functionToMethodCalls;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\Contract\ValueObject\ArgumentFuncCallToMethodCallInterface::class);
|
||||
$this->argumentFuncCallToMethodCalls = $configuration;
|
||||
}
|
||||
private function shouldSkipFuncCall(\PhpParser\Node\Expr\FuncCall $funcCall) : bool
|
||||
{
|
||||
|
@ -17,11 +17,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class FuncCallToConstFetchRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const FUNCTIONS_TO_CONSTANTS = 'functions_to_constants';
|
||||
/**
|
||||
* @var string[]
|
||||
*/
|
||||
@ -74,11 +69,9 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$functionsToConstants = $configuration[self::FUNCTIONS_TO_CONSTANTS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($functionsToConstants);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($functionsToConstants);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($functionsToConstants));
|
||||
/** @var array<string, string> $functionsToConstants */
|
||||
$this->functionsToConstants = $functionsToConstants;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($configuration));
|
||||
/** @var array<string, string> $configuration */
|
||||
$this->functionsToConstants = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -19,11 +19,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class FuncCallToMethodCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const FUNC_CALL_TO_CLASS_METHOD_CALL = 'function_to_class_to_method_call';
|
||||
/**
|
||||
* @var FuncCallToMethodCall[]
|
||||
*/
|
||||
@ -106,9 +101,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$funcCallsToClassMethodCalls = $configuration[self::FUNC_CALL_TO_CLASS_METHOD_CALL] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($funcCallsToClassMethodCalls);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($funcCallsToClassMethodCalls, \Rector\Transform\ValueObject\FuncCallToMethodCall::class);
|
||||
$this->funcNameToMethodCallNames = $funcCallsToClassMethodCalls;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\FuncCallToMethodCall::class);
|
||||
$this->funcNameToMethodCallNames = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -17,11 +17,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class FuncCallToNewRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const FUNCTIONS_TO_NEWS = 'functions_to_news';
|
||||
/**
|
||||
* @var string[]
|
||||
*/
|
||||
@ -73,9 +68,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$functionsToNews = $configuration[self::FUNCTIONS_TO_NEWS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($functionsToNews);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($functionsToNews);
|
||||
$this->functionToNew = $functionsToNews;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
$this->functionToNew = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -16,11 +16,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class FuncCallToStaticCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const FUNC_CALLS_TO_STATIC_CALLS = 'func_calls_to_static_calls';
|
||||
/**
|
||||
* @var FuncCallToStaticCall[]
|
||||
*/
|
||||
@ -54,9 +49,7 @@ final class FuncCallToStaticCallRector extends \Rector\Core\Rector\AbstractRecto
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$funcCallsToStaticCalls = $configuration[self::FUNC_CALLS_TO_STATIC_CALLS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($funcCallsToStaticCalls);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($funcCallsToStaticCalls, \Rector\Transform\ValueObject\FuncCallToStaticCall::class);
|
||||
$this->funcCallsToStaticCalls = $funcCallsToStaticCalls;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\FuncCallToStaticCall::class);
|
||||
$this->funcCallsToStaticCalls = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -18,11 +18,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class UnsetAndIssetToMethodCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const ISSET_UNSET_TO_METHOD_CALL = 'isset_unset_to_method_call';
|
||||
/**
|
||||
* @var UnsetAndIssetToMethodCall[]
|
||||
*/
|
||||
@ -74,10 +69,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$issetUnsetToMethodCalls = $configuration[self::ISSET_UNSET_TO_METHOD_CALL] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($issetUnsetToMethodCalls);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($issetUnsetToMethodCalls, \Rector\Transform\ValueObject\UnsetAndIssetToMethodCall::class);
|
||||
$this->issetUnsetToMethodCalls = $issetUnsetToMethodCalls;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\UnsetAndIssetToMethodCall::class);
|
||||
$this->issetUnsetToMethodCalls = $configuration;
|
||||
}
|
||||
private function processArrayDimFetchNode(\PhpParser\Node $node, \PhpParser\Node\Expr\ArrayDimFetch $arrayDimFetch, \Rector\Transform\ValueObject\UnsetAndIssetToMethodCall $unsetAndIssetToMethodCall) : ?\PhpParser\Node
|
||||
{
|
||||
|
@ -22,11 +22,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class CallableInMethodCallToVariableRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const CALLABLE_IN_METHOD_CALL_TO_VARIABLE = 'callable_in_method_call_to_variable';
|
||||
/**
|
||||
* @var CallableInMethodCallToVariable[]
|
||||
*/
|
||||
@ -108,9 +103,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$callableInMethodCallToVariable = $configuration[self::CALLABLE_IN_METHOD_CALL_TO_VARIABLE] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($callableInMethodCallToVariable);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($callableInMethodCallToVariable, \Rector\Transform\ValueObject\CallableInMethodCallToVariable::class);
|
||||
$this->callableInMethodCallToVariable = $callableInMethodCallToVariable;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\CallableInMethodCallToVariable::class);
|
||||
$this->callableInMethodCallToVariable = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -17,11 +17,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class MethodCallToAnotherMethodCallWithArgumentsRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const METHOD_CALL_RENAMES_WITH_ADDED_ARGUMENTS = 'method_call_renames_with_added_arguments';
|
||||
/**
|
||||
* @var MethodCallToAnotherMethodCallWithArguments[]
|
||||
*/
|
||||
@ -68,9 +63,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$methodCallRenamesWithAddedArguments = $configuration[self::METHOD_CALL_RENAMES_WITH_ADDED_ARGUMENTS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($methodCallRenamesWithAddedArguments);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($methodCallRenamesWithAddedArguments, \Rector\Transform\ValueObject\MethodCallToAnotherMethodCallWithArguments::class);
|
||||
$this->methodCallRenamesWithAddedArguments = $methodCallRenamesWithAddedArguments;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\MethodCallToAnotherMethodCallWithArguments::class);
|
||||
$this->methodCallRenamesWithAddedArguments = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -24,11 +24,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class MethodCallToMethodCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const METHOD_CALLS_TO_METHOD_CALLS = 'method_calls_to_method_calls';
|
||||
/**
|
||||
* @var MethodCallToMethodCall[]
|
||||
*/
|
||||
@ -130,9 +125,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$methodCallsToMethodsCalls = $configuration[self::METHOD_CALLS_TO_METHOD_CALLS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($methodCallsToMethodsCalls, \Rector\Transform\ValueObject\MethodCallToMethodCall::class);
|
||||
$this->methodCallsToMethodsCalls = $methodCallsToMethodsCalls;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\MethodCallToMethodCall::class);
|
||||
$this->methodCallsToMethodsCalls = $configuration;
|
||||
}
|
||||
private function isMatch(\PhpParser\Node\Expr\MethodCall $methodCall, \Rector\Transform\ValueObject\MethodCallToMethodCall $methodCallToMethodCall) : bool
|
||||
{
|
||||
|
@ -15,12 +15,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class MethodCallToPropertyFetchRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @api
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const METHOD_CALL_TO_PROPERTY_FETCHES = 'method_call_to_property_fetch_collection';
|
||||
/**
|
||||
* @var array<string, string>
|
||||
*/
|
||||
@ -72,10 +66,9 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$methodCallToPropertyFetchCollection = $configuration[self::METHOD_CALL_TO_PROPERTY_FETCHES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($methodCallToPropertyFetchCollection));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($methodCallToPropertyFetchCollection);
|
||||
/** @var array<string, string> $methodCallToPropertyFetchCollection */
|
||||
$this->methodCallToPropertyFetchCollection = $methodCallToPropertyFetchCollection;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($configuration));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
/** @var array<string, string> $configuration */
|
||||
$this->methodCallToPropertyFetchCollection = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -16,11 +16,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class MethodCallToStaticCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const METHOD_CALLS_TO_STATIC_CALLS = 'method_calls_to_static_calls';
|
||||
/**
|
||||
* @var MethodCallToStaticCall[]
|
||||
*/
|
||||
@ -89,9 +84,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$methodCallsToStaticCalls = $configuration[self::METHOD_CALLS_TO_STATIC_CALLS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($methodCallsToStaticCalls);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($methodCallsToStaticCalls, \Rector\Transform\ValueObject\MethodCallToStaticCall::class);
|
||||
$this->methodCallsToStaticCalls = $methodCallsToStaticCalls;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\MethodCallToStaticCall::class);
|
||||
$this->methodCallsToStaticCalls = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -16,11 +16,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class ReplaceParentCallByPropertyCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const PARENT_CALLS_TO_PROPERTIES = 'parent_calls_to_properties';
|
||||
/**
|
||||
* @var ReplaceParentCallByPropertyCall[]
|
||||
*/
|
||||
@ -76,8 +71,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$parentCallToProperties = $configuration[self::PARENT_CALLS_TO_PROPERTIES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($parentCallToProperties, \Rector\Transform\ValueObject\ReplaceParentCallByPropertyCall::class);
|
||||
$this->parentCallToProperties = $parentCallToProperties;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\ReplaceParentCallByPropertyCall::class);
|
||||
$this->parentCallToProperties = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -25,11 +25,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class ServiceGetterToConstructorInjectionRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const METHOD_CALL_TO_SERVICES = 'method_call_to_services';
|
||||
/**
|
||||
* @var ServiceGetterToConstructorInjection[]
|
||||
*/
|
||||
@ -162,9 +157,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$methodCallToServices = $configuration[self::METHOD_CALL_TO_SERVICES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($methodCallToServices);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($methodCallToServices, \Rector\Transform\ValueObject\ServiceGetterToConstructorInjection::class);
|
||||
$this->methodCallToServices = $methodCallToServices;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\ServiceGetterToConstructorInjection::class);
|
||||
$this->methodCallToServices = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -20,11 +20,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class NewArgToMethodCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const NEW_ARGS_TO_METHOD_CALLS = 'new_args_to_method_calls';
|
||||
/**
|
||||
* @var NewArgToMethodCall[]
|
||||
*/
|
||||
@ -88,9 +83,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$newArgsToMethodCalls = $configuration[self::NEW_ARGS_TO_METHOD_CALLS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($newArgsToMethodCalls);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($newArgsToMethodCalls, \Rector\Transform\ValueObject\NewArgToMethodCall::class);
|
||||
$this->newArgsToMethodCalls = $newArgsToMethodCalls;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\NewArgToMethodCall::class);
|
||||
$this->newArgsToMethodCalls = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -26,11 +26,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class NewToConstructorInjectionRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const TYPES_TO_CONSTRUCTOR_INJECTION = 'types_to_constructor_injection';
|
||||
/**
|
||||
* @var ObjectType[]
|
||||
*/
|
||||
@ -123,8 +118,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$typesToConstructorInjections = $configuration[self::TYPES_TO_CONSTRUCTOR_INJECTION] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($typesToConstructorInjections);
|
||||
$typesToConstructorInjections = $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($typesToConstructorInjections);
|
||||
foreach ($typesToConstructorInjections as $typeToConstructorInjection) {
|
||||
$this->constructorInjectionObjectTypes[] = new \PHPStan\Type\ObjectType($typeToConstructorInjection);
|
||||
}
|
||||
|
@ -24,11 +24,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class NewToMethodCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const NEWS_TO_METHOD_CALLS = 'news_to_method_calls';
|
||||
/**
|
||||
* @var NewToMethodCall[]
|
||||
*/
|
||||
@ -119,10 +114,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$newsToMethodCalls = $configuration[self::NEWS_TO_METHOD_CALLS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($newsToMethodCalls);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($newsToMethodCalls, \Rector\Transform\ValueObject\NewToMethodCall::class);
|
||||
$this->newsToMethodCalls = $newsToMethodCalls;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\NewToMethodCall::class);
|
||||
$this->newsToMethodCalls = $configuration;
|
||||
}
|
||||
private function getExistingFactoryPropertyName(\PhpParser\Node\Stmt\Class_ $class, \PHPStan\Type\ObjectType $factoryObjectType) : ?string
|
||||
{
|
||||
|
@ -16,11 +16,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class NewToStaticCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const TYPE_TO_STATIC_CALLS = 'type_to_static_calls';
|
||||
/**
|
||||
* @var NewToStaticCall[]
|
||||
*/
|
||||
@ -72,9 +67,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$typeToStaticCalls = $configuration[self::TYPE_TO_STATIC_CALLS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($typeToStaticCalls);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($typeToStaticCalls, \Rector\Transform\ValueObject\NewToStaticCall::class);
|
||||
$this->typeToStaticCalls = $typeToStaticCalls;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\NewToStaticCall::class);
|
||||
$this->typeToStaticCalls = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -18,11 +18,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class StaticCallToFuncCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const STATIC_CALLS_TO_FUNCTIONS = 'static_calls_to_functions';
|
||||
/**
|
||||
* @var StaticCallToFuncCall[]
|
||||
*/
|
||||
@ -66,9 +61,7 @@ final class StaticCallToFuncCallRector extends \Rector\Core\Rector\AbstractRecto
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$staticCallsToFunctions = $configuration[self::STATIC_CALLS_TO_FUNCTIONS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($staticCallsToFunctions);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($staticCallsToFunctions, \Rector\Transform\ValueObject\StaticCallToFuncCall::class);
|
||||
$this->staticCallsToFunctions = $staticCallsToFunctions;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\StaticCallToFuncCall::class);
|
||||
$this->staticCallsToFunctions = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -23,12 +23,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class StaticCallToMethodCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @api
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const STATIC_CALLS_TO_METHOD_CALLS = 'static_calls_to_method_calls';
|
||||
/**
|
||||
* @var StaticCallToMethodCall[]
|
||||
*/
|
||||
@ -123,10 +117,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$staticCallsToMethodCalls = $configuration[self::STATIC_CALLS_TO_METHOD_CALLS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($staticCallsToMethodCalls);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($staticCallsToMethodCalls, \Rector\Transform\ValueObject\StaticCallToMethodCall::class);
|
||||
$this->staticCallsToMethodCalls = $staticCallsToMethodCalls;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\StaticCallToMethodCall::class);
|
||||
$this->staticCallsToMethodCalls = $configuration;
|
||||
}
|
||||
private function refactorToInstanceCall(\PhpParser\Node\Expr\StaticCall $staticCall, \Rector\Transform\ValueObject\StaticCallToMethodCall $staticCallToMethodCall) : \PhpParser\Node\Expr\MethodCall
|
||||
{
|
||||
|
@ -20,11 +20,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class StaticCallToNewRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const STATIC_CALLS_TO_NEWS = 'static_calls_to_news';
|
||||
/**
|
||||
* @var StaticCallToNew[]
|
||||
*/
|
||||
@ -83,8 +78,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$staticCallsToNews = $configuration[self::STATIC_CALLS_TO_NEWS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($staticCallsToNews, \Rector\Transform\ValueObject\StaticCallToNew::class);
|
||||
$this->staticCallsToNews = $staticCallsToNews;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\StaticCallToNew::class);
|
||||
$this->staticCallsToNews = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -16,11 +16,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class StringToClassConstantRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const STRINGS_TO_CLASS_CONSTANTS = 'strings_to_class_constants';
|
||||
/**
|
||||
* @var StringToClassConstant[]
|
||||
*/
|
||||
@ -72,9 +67,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$stringToClassConstants = $configuration[self::STRINGS_TO_CLASS_CONSTANTS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($stringToClassConstants);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($stringToClassConstants, \Rector\Transform\ValueObject\StringToClassConstant::class);
|
||||
$this->stringsToClassConstants = $stringToClassConstants;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Transform\ValueObject\StringToClassConstant::class);
|
||||
$this->stringsToClassConstants = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -18,12 +18,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class ToStringToMethodCallRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @api
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const METHOD_NAMES_BY_TYPE = 'method_names_by_type';
|
||||
/**
|
||||
* @var array<string, string>
|
||||
*/
|
||||
@ -64,11 +58,10 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$methodNamesByType = $configuration[self::METHOD_NAMES_BY_TYPE] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($methodNamesByType));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($methodNamesByType);
|
||||
/** @var array<string, string> $methodNamesByType */
|
||||
$this->methodNamesByType = $methodNamesByType;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($configuration));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($configuration);
|
||||
/** @var array<string, string> $configuration */
|
||||
$this->methodNamesByType = $configuration;
|
||||
}
|
||||
private function processStringNode(\PhpParser\Node\Expr\Cast\String_ $string) : ?\PhpParser\Node
|
||||
{
|
||||
|
@ -26,11 +26,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class AddParamTypeDeclarationRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const PARAMETER_TYPEHINTS = 'parameter_typehints';
|
||||
/**
|
||||
* @var AddParamTypeDeclaration[]
|
||||
*/
|
||||
@ -97,10 +92,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$parameterTypehints = $configuration[self::PARAMETER_TYPEHINTS] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($parameterTypehints);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($parameterTypehints, \Rector\TypeDeclaration\ValueObject\AddParamTypeDeclaration::class);
|
||||
$this->addParamTypeDeclarations = $parameterTypehints;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\TypeDeclaration\ValueObject\AddParamTypeDeclaration::class);
|
||||
$this->addParamTypeDeclarations = $configuration;
|
||||
}
|
||||
private function shouldSkip(\PhpParser\Node\Stmt\ClassMethod $classMethod) : bool
|
||||
{
|
||||
|
@ -22,11 +22,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class AddReturnTypeDeclarationRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const METHOD_RETURN_TYPES = 'method_return_types';
|
||||
/**
|
||||
* @var AddReturnTypeDeclaration[]
|
||||
*/
|
||||
@ -90,10 +85,8 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$methodReturnTypes = $configuration[self::METHOD_RETURN_TYPES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($methodReturnTypes);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($methodReturnTypes, \Rector\TypeDeclaration\ValueObject\AddReturnTypeDeclaration::class);
|
||||
$this->methodReturnTypes = $methodReturnTypes;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\TypeDeclaration\ValueObject\AddReturnTypeDeclaration::class);
|
||||
$this->methodReturnTypes = $configuration;
|
||||
}
|
||||
private function processClassMethodNodeWithTypehints(\PhpParser\Node\Stmt\ClassMethod $classMethod, \PHPStan\Type\Type $newType) : void
|
||||
{
|
||||
|
@ -18,11 +18,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class ChangeConstantVisibilityRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const CLASS_CONSTANT_VISIBILITY_CHANGES = 'class_constant_visibility_changes';
|
||||
/**
|
||||
* @var ChangeConstantVisibility[]
|
||||
*/
|
||||
@ -91,9 +86,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$classConstantVisibilityChanges = $configuration[self::CLASS_CONSTANT_VISIBILITY_CHANGES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($classConstantVisibilityChanges);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($classConstantVisibilityChanges, \Rector\Visibility\ValueObject\ChangeConstantVisibility::class);
|
||||
$this->classConstantVisibilityChanges = $classConstantVisibilityChanges;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Visibility\ValueObject\ChangeConstantVisibility::class);
|
||||
$this->classConstantVisibilityChanges = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -21,11 +21,6 @@ use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
*/
|
||||
final class ChangeMethodVisibilityRector extends \Rector\Core\Rector\AbstractRector implements \Rector\Core\Contract\Rector\ConfigurableRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const METHOD_VISIBILITIES = 'method_visibilities';
|
||||
/**
|
||||
* @var ChangeMethodVisibility[]
|
||||
*/
|
||||
@ -116,9 +111,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$methodVisibilities = $configuration[self::METHOD_VISIBILITIES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($methodVisibilities);
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($methodVisibilities, \Rector\Visibility\ValueObject\ChangeMethodVisibility::class);
|
||||
$this->methodVisibilities = $methodVisibilities;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allIsAOf($configuration, \Rector\Visibility\ValueObject\ChangeMethodVisibility::class);
|
||||
$this->methodVisibilities = $configuration;
|
||||
}
|
||||
}
|
||||
|
@ -16,11 +16,11 @@ final class VersionResolver
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public const PACKAGE_VERSION = '1ed8242e4462ace3beabc12632d1f8f4638bd7c3';
|
||||
public const PACKAGE_VERSION = '9f98873278a129166bfe7b65829d09f5de76d679';
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public const RELEASE_DATE = '2022-02-18 01:00:33';
|
||||
public const RELEASE_DATE = '2022-02-18 02:39:44';
|
||||
public static function resolvePackageVersion() : string
|
||||
{
|
||||
$process = new \RectorPrefix20220218\Symfony\Component\Process\Process(['git', 'log', '--pretty="%H"', '-n1', 'HEAD'], __DIR__);
|
||||
|
@ -14,11 +14,6 @@ use Symplify\RuleDocGenerator\ValueObject\RuleDefinition;
|
||||
use RectorPrefix20220218\Webmozart\Assert\Assert;
|
||||
final class RenameClassNonPhpRector implements \Rector\Core\Contract\Rector\NonPhpRectorInterface, \Symplify\RuleDocGenerator\Contract\ConfigurableRuleInterface, \Rector\Core\Contract\Rector\ConfigurableRectorInterface, \Rector\PostRector\Contract\Rector\ComplementaryRectorInterface
|
||||
{
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
*/
|
||||
public const RENAME_CLASSES = 'rename_classes';
|
||||
/**
|
||||
* @see https://regex101.com/r/HKUFJD/7
|
||||
* for "?<!" @see https://stackoverflow.com/a/3735908/1348344
|
||||
@ -66,8 +61,7 @@ CODE_SAMPLE
|
||||
*/
|
||||
public function configure(array $configuration) : void
|
||||
{
|
||||
$renameClasses = $configuration[self::RENAME_CLASSES] ?? $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::isArray($renameClasses);
|
||||
$renameClasses = $configuration;
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString(\array_keys($renameClasses));
|
||||
\RectorPrefix20220218\Webmozart\Assert\Assert::allString($renameClasses);
|
||||
$this->renameClasses = $renameClasses;
|
||||
|
2
vendor/autoload.php
vendored
2
vendor/autoload.php
vendored
@ -4,4 +4,4 @@
|
||||
|
||||
require_once __DIR__ . '/composer/autoload_real.php';
|
||||
|
||||
return ComposerAutoloaderInit6803c5aa61198f26a2560abb9252e1ec::getLoader();
|
||||
return ComposerAutoloaderInitcccf105135239365f6b7d34222334fcd::getLoader();
|
||||
|
14
vendor/composer/autoload_real.php
vendored
14
vendor/composer/autoload_real.php
vendored
@ -2,7 +2,7 @@
|
||||
|
||||
// autoload_real.php @generated by Composer
|
||||
|
||||
class ComposerAutoloaderInit6803c5aa61198f26a2560abb9252e1ec
|
||||
class ComposerAutoloaderInitcccf105135239365f6b7d34222334fcd
|
||||
{
|
||||
private static $loader;
|
||||
|
||||
@ -22,15 +22,15 @@ class ComposerAutoloaderInit6803c5aa61198f26a2560abb9252e1ec
|
||||
return self::$loader;
|
||||
}
|
||||
|
||||
spl_autoload_register(array('ComposerAutoloaderInit6803c5aa61198f26a2560abb9252e1ec', 'loadClassLoader'), true, true);
|
||||
spl_autoload_register(array('ComposerAutoloaderInitcccf105135239365f6b7d34222334fcd', 'loadClassLoader'), true, true);
|
||||
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__)));
|
||||
spl_autoload_unregister(array('ComposerAutoloaderInit6803c5aa61198f26a2560abb9252e1ec', 'loadClassLoader'));
|
||||
spl_autoload_unregister(array('ComposerAutoloaderInitcccf105135239365f6b7d34222334fcd', 'loadClassLoader'));
|
||||
|
||||
$useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
|
||||
if ($useStaticLoader) {
|
||||
require __DIR__ . '/autoload_static.php';
|
||||
|
||||
call_user_func(\Composer\Autoload\ComposerStaticInit6803c5aa61198f26a2560abb9252e1ec::getInitializer($loader));
|
||||
call_user_func(\Composer\Autoload\ComposerStaticInitcccf105135239365f6b7d34222334fcd::getInitializer($loader));
|
||||
} else {
|
||||
$classMap = require __DIR__ . '/autoload_classmap.php';
|
||||
if ($classMap) {
|
||||
@ -42,12 +42,12 @@ class ComposerAutoloaderInit6803c5aa61198f26a2560abb9252e1ec
|
||||
$loader->register(true);
|
||||
|
||||
if ($useStaticLoader) {
|
||||
$includeFiles = Composer\Autoload\ComposerStaticInit6803c5aa61198f26a2560abb9252e1ec::$files;
|
||||
$includeFiles = Composer\Autoload\ComposerStaticInitcccf105135239365f6b7d34222334fcd::$files;
|
||||
} else {
|
||||
$includeFiles = require __DIR__ . '/autoload_files.php';
|
||||
}
|
||||
foreach ($includeFiles as $fileIdentifier => $file) {
|
||||
composerRequire6803c5aa61198f26a2560abb9252e1ec($fileIdentifier, $file);
|
||||
composerRequirecccf105135239365f6b7d34222334fcd($fileIdentifier, $file);
|
||||
}
|
||||
|
||||
return $loader;
|
||||
@ -59,7 +59,7 @@ class ComposerAutoloaderInit6803c5aa61198f26a2560abb9252e1ec
|
||||
* @param string $file
|
||||
* @return void
|
||||
*/
|
||||
function composerRequire6803c5aa61198f26a2560abb9252e1ec($fileIdentifier, $file)
|
||||
function composerRequirecccf105135239365f6b7d34222334fcd($fileIdentifier, $file)
|
||||
{
|
||||
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
|
||||
$GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;
|
||||
|
8
vendor/composer/autoload_static.php
vendored
8
vendor/composer/autoload_static.php
vendored
@ -4,7 +4,7 @@
|
||||
|
||||
namespace Composer\Autoload;
|
||||
|
||||
class ComposerStaticInit6803c5aa61198f26a2560abb9252e1ec
|
||||
class ComposerStaticInitcccf105135239365f6b7d34222334fcd
|
||||
{
|
||||
public static $files = array (
|
||||
'0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => __DIR__ . '/..' . '/symfony/polyfill-mbstring/bootstrap.php',
|
||||
@ -3871,9 +3871,9 @@ class ComposerStaticInit6803c5aa61198f26a2560abb9252e1ec
|
||||
public static function getInitializer(ClassLoader $loader)
|
||||
{
|
||||
return \Closure::bind(function () use ($loader) {
|
||||
$loader->prefixLengthsPsr4 = ComposerStaticInit6803c5aa61198f26a2560abb9252e1ec::$prefixLengthsPsr4;
|
||||
$loader->prefixDirsPsr4 = ComposerStaticInit6803c5aa61198f26a2560abb9252e1ec::$prefixDirsPsr4;
|
||||
$loader->classMap = ComposerStaticInit6803c5aa61198f26a2560abb9252e1ec::$classMap;
|
||||
$loader->prefixLengthsPsr4 = ComposerStaticInitcccf105135239365f6b7d34222334fcd::$prefixLengthsPsr4;
|
||||
$loader->prefixDirsPsr4 = ComposerStaticInitcccf105135239365f6b7d34222334fcd::$prefixDirsPsr4;
|
||||
$loader->classMap = ComposerStaticInitcccf105135239365f6b7d34222334fcd::$classMap;
|
||||
|
||||
}, null, ClassLoader::class);
|
||||
}
|
||||
|
10
vendor/scoper-autoload.php
vendored
10
vendor/scoper-autoload.php
vendored
@ -9,8 +9,8 @@ $loader = require_once __DIR__.'/autoload.php';
|
||||
if (!class_exists('AutoloadIncluder', false) && !interface_exists('AutoloadIncluder', false) && !trait_exists('AutoloadIncluder', false)) {
|
||||
spl_autoload_call('RectorPrefix20220218\AutoloadIncluder');
|
||||
}
|
||||
if (!class_exists('ComposerAutoloaderInit6803c5aa61198f26a2560abb9252e1ec', false) && !interface_exists('ComposerAutoloaderInit6803c5aa61198f26a2560abb9252e1ec', false) && !trait_exists('ComposerAutoloaderInit6803c5aa61198f26a2560abb9252e1ec', false)) {
|
||||
spl_autoload_call('RectorPrefix20220218\ComposerAutoloaderInit6803c5aa61198f26a2560abb9252e1ec');
|
||||
if (!class_exists('ComposerAutoloaderInitcccf105135239365f6b7d34222334fcd', false) && !interface_exists('ComposerAutoloaderInitcccf105135239365f6b7d34222334fcd', false) && !trait_exists('ComposerAutoloaderInitcccf105135239365f6b7d34222334fcd', false)) {
|
||||
spl_autoload_call('RectorPrefix20220218\ComposerAutoloaderInitcccf105135239365f6b7d34222334fcd');
|
||||
}
|
||||
if (!class_exists('Helmich\TypoScriptParser\Parser\AST\Statement', false) && !interface_exists('Helmich\TypoScriptParser\Parser\AST\Statement', false) && !trait_exists('Helmich\TypoScriptParser\Parser\AST\Statement', false)) {
|
||||
spl_autoload_call('RectorPrefix20220218\Helmich\TypoScriptParser\Parser\AST\Statement');
|
||||
@ -59,9 +59,9 @@ if (!function_exists('print_node')) {
|
||||
return \RectorPrefix20220218\print_node(...func_get_args());
|
||||
}
|
||||
}
|
||||
if (!function_exists('composerRequire6803c5aa61198f26a2560abb9252e1ec')) {
|
||||
function composerRequire6803c5aa61198f26a2560abb9252e1ec() {
|
||||
return \RectorPrefix20220218\composerRequire6803c5aa61198f26a2560abb9252e1ec(...func_get_args());
|
||||
if (!function_exists('composerRequirecccf105135239365f6b7d34222334fcd')) {
|
||||
function composerRequirecccf105135239365f6b7d34222334fcd() {
|
||||
return \RectorPrefix20220218\composerRequirecccf105135239365f6b7d34222334fcd(...func_get_args());
|
||||
}
|
||||
}
|
||||
if (!function_exists('scanPath')) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user