diff --git a/.github/workflows/php.yml b/.github/workflows/php.yml index 6e5b032..2eda52d 100644 --- a/.github/workflows/php.yml +++ b/.github/workflows/php.yml @@ -16,7 +16,7 @@ jobs: strategy: matrix: - php-versions: ['8.2', '8.3'] + php-versions: ['8.3', '8.4'] steps: - name: Checkout diff --git a/.travis.yml b/.travis.yml index 1977fba..cf58bcf 100644 --- a/.travis.yml +++ b/.travis.yml @@ -2,7 +2,8 @@ language: php php: - '8.1' - '8.2' - - '8.3'' + - '8.3' + - '8.4' env: - SYMFONY_DEPRECATIONS_HELPER=disabled diff --git a/composer.json b/composer.json index d7b01ae..4fdf3a7 100644 --- a/composer.json +++ b/composer.json @@ -4,20 +4,20 @@ "license": "MIT", "description": "A small etl coded in php, to extract/transform/load Edit with ease.", "require": { - "php": ">=8.2", + "php": ">=8.3", "oliverde8/associative-array-simplified": "^1.0", "psr/log": "^2.0|^3.0", - "symfony/expression-language": "^6.0|^7.0", - "symfony/filesystem": "^6.0|^7.0", - "symfony/validator": "^6.0|^7.0", - "symfony/yaml": "^6.0|^7.0" + "symfony/expression-language": "^8.0", + "symfony/filesystem": "^7.0|^8.0", + "symfony/validator": "^7.0|^8.0", + "symfony/yaml": "^7.0|^8.0" }, "require-dev": { "phpunit/php-code-coverage": "^9.2", "phpunit/phpunit": "^9.6", "rector/rector": "^1.2", - "symfony/console": "^7.1", - "symfony/http-client": "^7.2" + "symfony/console": "^7.0|^8.0", + "symfony/http-client": "^7.0|^8.0" }, "suggest": { "league/flysystem": "For transfaring files from external file systems", diff --git a/composer.lock b/composer.lock new file mode 100644 index 0000000..ca5321c --- /dev/null +++ b/composer.lock @@ -0,0 +1,3613 @@ +{ + "_readme": [ + "This file locks the dependencies of your project to a known state", + "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", + "This file is @generated automatically" + ], + "content-hash": "6508b40b3fd0bba112c2643331533988", + "packages": [ + { + "name": "oliverde8/associative-array-simplified", + "version": "1.0.0", + "source": { + "type": "git", + "url": "https://github.com/oliverde8/AssociativeArraySimplified.git", + "reference": "aa1af7c404d62879140a76e8e9404584c7776b5f" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/oliverde8/AssociativeArraySimplified/zipball/aa1af7c404d62879140a76e8e9404584c7776b5f", + "reference": "aa1af7c404d62879140a76e8e9404584c7776b5f", + "shasum": "" + }, + "require": { + "php": ">=5.5.0" + }, + "require-dev": { + "phpunit/phpunit": "4.*" + }, + "type": "library", + "autoload": { + "psr-4": { + "oliverde8\\AssociativeArraySimplified\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Oliver de Cramer", + "homepage": "http://oliver-decramer.com" + } + ], + "description": "Allow simplified manupulation of recursive associative arrays.", + "support": { + "issues": "https://github.com/oliverde8/AssociativeArraySimplified/issues", + "source": "https://github.com/oliverde8/AssociativeArraySimplified/tree/master" + }, + "time": "2017-02-17T10:14:26+00:00" + }, + { + "name": "psr/cache", + "version": "3.0.0", + "source": { + "type": "git", + "url": "https://github.com/php-fig/cache.git", + "reference": "aa5030cfa5405eccfdcb1083ce040c2cb8d253bf" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/cache/zipball/aa5030cfa5405eccfdcb1083ce040c2cb8d253bf", + "reference": "aa5030cfa5405eccfdcb1083ce040c2cb8d253bf", + "shasum": "" + }, + "require": { + "php": ">=8.0.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Cache\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "https://www.php-fig.org/" + } + ], + "description": "Common interface for caching libraries", + "keywords": [ + "cache", + "psr", + "psr-6" + ], + "support": { + "source": "https://github.com/php-fig/cache/tree/3.0.0" + }, + "time": "2021-02-03T23:26:27+00:00" + }, + { + "name": "psr/container", + "version": "2.0.2", + "source": { + "type": "git", + "url": "https://github.com/php-fig/container.git", + "reference": "c71ecc56dfe541dbd90c5360474fbc405f8d5963" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/container/zipball/c71ecc56dfe541dbd90c5360474fbc405f8d5963", + "reference": "c71ecc56dfe541dbd90c5360474fbc405f8d5963", + "shasum": "" + }, + "require": { + "php": ">=7.4.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Container\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "https://www.php-fig.org/" + } + ], + "description": "Common Container Interface (PHP FIG PSR-11)", + "homepage": "https://github.com/php-fig/container", + "keywords": [ + "PSR-11", + "container", + "container-interface", + "container-interop", + "psr" + ], + "support": { + "issues": "https://github.com/php-fig/container/issues", + "source": "https://github.com/php-fig/container/tree/2.0.2" + }, + "time": "2021-11-05T16:47:00+00:00" + }, + { + "name": "psr/log", + "version": "3.0.2", + "source": { + "type": "git", + "url": "https://github.com/php-fig/log.git", + "reference": "f16e1d5863e37f8d8c2a01719f5b34baa2b714d3" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/log/zipball/f16e1d5863e37f8d8c2a01719f5b34baa2b714d3", + "reference": "f16e1d5863e37f8d8c2a01719f5b34baa2b714d3", + "shasum": "" + }, + "require": { + "php": ">=8.0.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Log\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "https://www.php-fig.org/" + } + ], + "description": "Common interface for logging libraries", + "homepage": "https://github.com/php-fig/log", + "keywords": [ + "log", + "psr", + "psr-3" + ], + "support": { + "source": "https://github.com/php-fig/log/tree/3.0.2" + }, + "time": "2024-09-11T13:17:53+00:00" + }, + { + "name": "symfony/cache", + "version": "v8.0.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/cache.git", + "reference": "0e67dc8145810d4e1c0d13c0e1d29ceb930b1c8e" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/cache/zipball/0e67dc8145810d4e1c0d13c0e1d29ceb930b1c8e", + "reference": "0e67dc8145810d4e1c0d13c0e1d29ceb930b1c8e", + "shasum": "" + }, + "require": { + "php": ">=8.4", + "psr/cache": "^2.0|^3.0", + "psr/log": "^1.1|^2|^3", + "symfony/cache-contracts": "^3.6", + "symfony/service-contracts": "^2.5|^3", + "symfony/var-exporter": "^7.4|^8.0" + }, + "conflict": { + "doctrine/dbal": "<4.3", + "ext-redis": "<6.1", + "ext-relay": "<0.12.1" + }, + "provide": { + "psr/cache-implementation": "2.0|3.0", + "psr/simple-cache-implementation": "1.0|2.0|3.0", + "symfony/cache-implementation": "1.1|2.0|3.0" + }, + "require-dev": { + "cache/integration-tests": "dev-master", + "doctrine/dbal": "^4.3", + "predis/predis": "^1.1|^2.0", + "psr/simple-cache": "^1.0|^2.0|^3.0", + "symfony/clock": "^7.4|^8.0", + "symfony/config": "^7.4|^8.0", + "symfony/dependency-injection": "^7.4|^8.0", + "symfony/filesystem": "^7.4|^8.0", + "symfony/http-kernel": "^7.4|^8.0", + "symfony/messenger": "^7.4|^8.0", + "symfony/var-dumper": "^7.4|^8.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Cache\\": "" + }, + "classmap": [ + "Traits/ValueWrapper.php" + ], + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides extended PSR-6, PSR-16 (and tags) implementations", + "homepage": "https://symfony.com", + "keywords": [ + "caching", + "psr6" + ], + "support": { + "source": "https://github.com/symfony/cache/tree/v8.0.1" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2025-12-04T18:17:06+00:00" + }, + { + "name": "symfony/cache-contracts", + "version": "v3.6.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/cache-contracts.git", + "reference": "5d68a57d66910405e5c0b63d6f0af941e66fc868" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/cache-contracts/zipball/5d68a57d66910405e5c0b63d6f0af941e66fc868", + "reference": "5d68a57d66910405e5c0b63d6f0af941e66fc868", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "psr/cache": "^3.0" + }, + "type": "library", + "extra": { + "thanks": { + "url": "https://github.com/symfony/contracts", + "name": "symfony/contracts" + }, + "branch-alias": { + "dev-main": "3.6-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Contracts\\Cache\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Generic abstractions related to caching", + "homepage": "https://symfony.com", + "keywords": [ + "abstractions", + "contracts", + "decoupling", + "interfaces", + "interoperability", + "standards" + ], + "support": { + "source": "https://github.com/symfony/cache-contracts/tree/v3.6.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2025-03-13T15:25:07+00:00" + }, + { + "name": "symfony/deprecation-contracts", + "version": "v3.6.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/deprecation-contracts.git", + "reference": "63afe740e99a13ba87ec199bb07bbdee937a5b62" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/63afe740e99a13ba87ec199bb07bbdee937a5b62", + "reference": "63afe740e99a13ba87ec199bb07bbdee937a5b62", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "type": "library", + "extra": { + "thanks": { + "url": "https://github.com/symfony/contracts", + "name": "symfony/contracts" + }, + "branch-alias": { + "dev-main": "3.6-dev" + } + }, + "autoload": { + "files": [ + "function.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "A generic function and convention to trigger deprecation notices", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/deprecation-contracts/tree/v3.6.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-09-25T14:21:43+00:00" + }, + { + "name": "symfony/expression-language", + "version": "v8.0.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/expression-language.git", + "reference": "43f520aef59d2fd089662d721b39e0101bb69232" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/expression-language/zipball/43f520aef59d2fd089662d721b39e0101bb69232", + "reference": "43f520aef59d2fd089662d721b39e0101bb69232", + "shasum": "" + }, + "require": { + "php": ">=8.4", + "symfony/cache": "^7.4|^8.0", + "symfony/service-contracts": "^2.5|^3" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\ExpressionLanguage\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides an engine that can compile and evaluate expressions", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/expression-language/tree/v8.0.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2025-11-12T15:46:48+00:00" + }, + { + "name": "symfony/filesystem", + "version": "v8.0.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/filesystem.git", + "reference": "d937d400b980523dc9ee946bb69972b5e619058d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/d937d400b980523dc9ee946bb69972b5e619058d", + "reference": "d937d400b980523dc9ee946bb69972b5e619058d", + "shasum": "" + }, + "require": { + "php": ">=8.4", + "symfony/polyfill-ctype": "~1.8", + "symfony/polyfill-mbstring": "~1.8" + }, + "require-dev": { + "symfony/process": "^7.4|^8.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Filesystem\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides basic utilities for the filesystem", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/filesystem/tree/v8.0.1" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2025-12-01T09:13:36+00:00" + }, + { + "name": "symfony/polyfill-ctype", + "version": "v1.33.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-ctype.git", + "reference": "a3cc8b044a6ea513310cbd48ef7333b384945638" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/a3cc8b044a6ea513310cbd48ef7333b384945638", + "reference": "a3cc8b044a6ea513310cbd48ef7333b384945638", + "shasum": "" + }, + "require": { + "php": ">=7.2" + }, + "provide": { + "ext-ctype": "*" + }, + "suggest": { + "ext-ctype": "For best performance" + }, + "type": "library", + "extra": { + "thanks": { + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Ctype\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Gert de Pagter", + "email": "BackEndTea@gmail.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for ctype functions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "ctype", + "polyfill", + "portable" + ], + "support": { + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.33.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-09-09T11:45:10+00:00" + }, + { + "name": "symfony/polyfill-mbstring", + "version": "v1.33.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-mbstring.git", + "reference": "6d857f4d76bd4b343eac26d6b539585d2bc56493" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/6d857f4d76bd4b343eac26d6b539585d2bc56493", + "reference": "6d857f4d76bd4b343eac26d6b539585d2bc56493", + "shasum": "" + }, + "require": { + "ext-iconv": "*", + "php": ">=7.2" + }, + "provide": { + "ext-mbstring": "*" + }, + "suggest": { + "ext-mbstring": "For best performance" + }, + "type": "library", + "extra": { + "thanks": { + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Mbstring\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for the Mbstring extension", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "mbstring", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.33.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-12-23T08:48:59+00:00" + }, + { + "name": "symfony/service-contracts", + "version": "v3.6.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/service-contracts.git", + "reference": "45112560a3ba2d715666a509a0bc9521d10b6c43" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/service-contracts/zipball/45112560a3ba2d715666a509a0bc9521d10b6c43", + "reference": "45112560a3ba2d715666a509a0bc9521d10b6c43", + "shasum": "" + }, + "require": { + "php": ">=8.1", + "psr/container": "^1.1|^2.0", + "symfony/deprecation-contracts": "^2.5|^3" + }, + "conflict": { + "ext-psr": "<1.1|>=2" + }, + "type": "library", + "extra": { + "thanks": { + "url": "https://github.com/symfony/contracts", + "name": "symfony/contracts" + }, + "branch-alias": { + "dev-main": "3.6-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Contracts\\Service\\": "" + }, + "exclude-from-classmap": [ + "/Test/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Generic abstractions related to writing services", + "homepage": "https://symfony.com", + "keywords": [ + "abstractions", + "contracts", + "decoupling", + "interfaces", + "interoperability", + "standards" + ], + "support": { + "source": "https://github.com/symfony/service-contracts/tree/v3.6.1" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2025-07-15T11:30:57+00:00" + }, + { + "name": "symfony/translation-contracts", + "version": "v3.6.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/translation-contracts.git", + "reference": "65a8bc82080447fae78373aa10f8d13b38338977" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/65a8bc82080447fae78373aa10f8d13b38338977", + "reference": "65a8bc82080447fae78373aa10f8d13b38338977", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "type": "library", + "extra": { + "thanks": { + "url": "https://github.com/symfony/contracts", + "name": "symfony/contracts" + }, + "branch-alias": { + "dev-main": "3.6-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Contracts\\Translation\\": "" + }, + "exclude-from-classmap": [ + "/Test/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Generic abstractions related to translation", + "homepage": "https://symfony.com", + "keywords": [ + "abstractions", + "contracts", + "decoupling", + "interfaces", + "interoperability", + "standards" + ], + "support": { + "source": "https://github.com/symfony/translation-contracts/tree/v3.6.1" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2025-07-15T13:41:35+00:00" + }, + { + "name": "symfony/validator", + "version": "v8.0.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/validator.git", + "reference": "9a98d365b29a4f6116a2e2b6ca62d8a7179a86e1" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/validator/zipball/9a98d365b29a4f6116a2e2b6ca62d8a7179a86e1", + "reference": "9a98d365b29a4f6116a2e2b6ca62d8a7179a86e1", + "shasum": "" + }, + "require": { + "php": ">=8.4", + "symfony/polyfill-ctype": "^1.8", + "symfony/polyfill-mbstring": "^1.0", + "symfony/translation-contracts": "^2.5|^3" + }, + "conflict": { + "doctrine/lexer": "<1.1", + "symfony/doctrine-bridge": "<7.4" + }, + "require-dev": { + "egulias/email-validator": "^2.1.10|^3|^4", + "symfony/cache": "^7.4|^8.0", + "symfony/config": "^7.4|^8.0", + "symfony/console": "^7.4|^8.0", + "symfony/dependency-injection": "^7.4|^8.0", + "symfony/expression-language": "^7.4|^8.0", + "symfony/finder": "^7.4|^8.0", + "symfony/http-client": "^7.4|^8.0", + "symfony/http-foundation": "^7.4|^8.0", + "symfony/http-kernel": "^7.4|^8.0", + "symfony/intl": "^7.4|^8.0", + "symfony/mime": "^7.4|^8.0", + "symfony/process": "^7.4|^8.0", + "symfony/property-access": "^7.4|^8.0", + "symfony/property-info": "^7.4|^8.0", + "symfony/string": "^7.4|^8.0", + "symfony/translation": "^7.4|^8.0", + "symfony/type-info": "^7.4|^8.0", + "symfony/yaml": "^7.4|^8.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Validator\\": "" + }, + "exclude-from-classmap": [ + "/Tests/", + "/Resources/bin/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides tools to validate values", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/validator/tree/v8.0.2" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2025-12-08T06:57:48+00:00" + }, + { + "name": "symfony/var-exporter", + "version": "v8.0.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/var-exporter.git", + "reference": "7345f46c251f2eb27c7b3ebdb5bb076b3ffcae04" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/var-exporter/zipball/7345f46c251f2eb27c7b3ebdb5bb076b3ffcae04", + "reference": "7345f46c251f2eb27c7b3ebdb5bb076b3ffcae04", + "shasum": "" + }, + "require": { + "php": ">=8.4" + }, + "require-dev": { + "symfony/property-access": "^7.4|^8.0", + "symfony/serializer": "^7.4|^8.0", + "symfony/var-dumper": "^7.4|^8.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\VarExporter\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Allows exporting any serializable PHP data structure to plain PHP code", + "homepage": "https://symfony.com", + "keywords": [ + "clone", + "construct", + "export", + "hydrate", + "instantiate", + "lazy-loading", + "proxy", + "serialize" + ], + "support": { + "source": "https://github.com/symfony/var-exporter/tree/v8.0.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2025-11-05T18:53:00+00:00" + }, + { + "name": "symfony/yaml", + "version": "v8.0.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/yaml.git", + "reference": "7a1a90ba1df6e821a6b53c4cabdc32a56cabfb14" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/yaml/zipball/7a1a90ba1df6e821a6b53c4cabdc32a56cabfb14", + "reference": "7a1a90ba1df6e821a6b53c4cabdc32a56cabfb14", + "shasum": "" + }, + "require": { + "php": ">=8.4", + "symfony/polyfill-ctype": "^1.8" + }, + "conflict": { + "symfony/console": "<7.4" + }, + "require-dev": { + "symfony/console": "^7.4|^8.0" + }, + "bin": [ + "Resources/bin/yaml-lint" + ], + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Yaml\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Loads and dumps YAML files", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/yaml/tree/v8.0.1" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2025-12-04T18:17:06+00:00" + } + ], + "packages-dev": [ + { + "name": "doctrine/instantiator", + "version": "2.0.0", + "source": { + "type": "git", + "url": "https://github.com/doctrine/instantiator.git", + "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", + "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", + "shasum": "" + }, + "require": { + "php": "^8.1" + }, + "require-dev": { + "doctrine/coding-standard": "^11", + "ext-pdo": "*", + "ext-phar": "*", + "phpbench/phpbench": "^1.2", + "phpstan/phpstan": "^1.9.4", + "phpstan/phpstan-phpunit": "^1.3", + "phpunit/phpunit": "^9.5.27", + "vimeo/psalm": "^5.4" + }, + "type": "library", + "autoload": { + "psr-4": { + "Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Marco Pivetta", + "email": "ocramius@gmail.com", + "homepage": "https://ocramius.github.io/" + } + ], + "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", + "homepage": "https://www.doctrine-project.org/projects/instantiator.html", + "keywords": [ + "constructor", + "instantiate" + ], + "support": { + "issues": "https://github.com/doctrine/instantiator/issues", + "source": "https://github.com/doctrine/instantiator/tree/2.0.0" + }, + "funding": [ + { + "url": "https://www.doctrine-project.org/sponsorship.html", + "type": "custom" + }, + { + "url": "https://www.patreon.com/phpdoctrine", + "type": "patreon" + }, + { + "url": "https://tidelift.com/funding/github/packagist/doctrine%2Finstantiator", + "type": "tidelift" + } + ], + "time": "2022-12-30T00:23:10+00:00" + }, + { + "name": "myclabs/deep-copy", + "version": "1.13.4", + "source": { + "type": "git", + "url": "https://github.com/myclabs/DeepCopy.git", + "reference": "07d290f0c47959fd5eed98c95ee5602db07e0b6a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/07d290f0c47959fd5eed98c95ee5602db07e0b6a", + "reference": "07d290f0c47959fd5eed98c95ee5602db07e0b6a", + "shasum": "" + }, + "require": { + "php": "^7.1 || ^8.0" + }, + "conflict": { + "doctrine/collections": "<1.6.8", + "doctrine/common": "<2.13.3 || >=3 <3.2.2" + }, + "require-dev": { + "doctrine/collections": "^1.6.8", + "doctrine/common": "^2.13.3 || ^3.2.2", + "phpspec/prophecy": "^1.10", + "phpunit/phpunit": "^7.5.20 || ^8.5.23 || ^9.5.13" + }, + "type": "library", + "autoload": { + "files": [ + "src/DeepCopy/deep_copy.php" + ], + "psr-4": { + "DeepCopy\\": "src/DeepCopy/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "Create deep copies (clones) of your objects", + "keywords": [ + "clone", + "copy", + "duplicate", + "object", + "object graph" + ], + "support": { + "issues": "https://github.com/myclabs/DeepCopy/issues", + "source": "https://github.com/myclabs/DeepCopy/tree/1.13.4" + }, + "funding": [ + { + "url": "https://tidelift.com/funding/github/packagist/myclabs/deep-copy", + "type": "tidelift" + } + ], + "time": "2025-08-01T08:46:24+00:00" + }, + { + "name": "nikic/php-parser", + "version": "v5.7.0", + "source": { + "type": "git", + "url": "https://github.com/nikic/PHP-Parser.git", + "reference": "dca41cd15c2ac9d055ad70dbfd011130757d1f82" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/dca41cd15c2ac9d055ad70dbfd011130757d1f82", + "reference": "dca41cd15c2ac9d055ad70dbfd011130757d1f82", + "shasum": "" + }, + "require": { + "ext-ctype": "*", + "ext-json": "*", + "ext-tokenizer": "*", + "php": ">=7.4" + }, + "require-dev": { + "ircmaxell/php-yacc": "^0.0.7", + "phpunit/phpunit": "^9.0" + }, + "bin": [ + "bin/php-parse" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "5.x-dev" + } + }, + "autoload": { + "psr-4": { + "PhpParser\\": "lib/PhpParser" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Nikita Popov" + } + ], + "description": "A PHP parser written in PHP", + "keywords": [ + "parser", + "php" + ], + "support": { + "issues": "https://github.com/nikic/PHP-Parser/issues", + "source": "https://github.com/nikic/PHP-Parser/tree/v5.7.0" + }, + "time": "2025-12-06T11:56:16+00:00" + }, + { + "name": "phar-io/manifest", + "version": "2.0.4", + "source": { + "type": "git", + "url": "https://github.com/phar-io/manifest.git", + "reference": "54750ef60c58e43759730615a392c31c80e23176" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phar-io/manifest/zipball/54750ef60c58e43759730615a392c31c80e23176", + "reference": "54750ef60c58e43759730615a392c31c80e23176", + "shasum": "" + }, + "require": { + "ext-dom": "*", + "ext-libxml": "*", + "ext-phar": "*", + "ext-xmlwriter": "*", + "phar-io/version": "^3.0.1", + "php": "^7.2 || ^8.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Arne Blankerts", + "email": "arne@blankerts.de", + "role": "Developer" + }, + { + "name": "Sebastian Heuer", + "email": "sebastian@phpeople.de", + "role": "Developer" + }, + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "Developer" + } + ], + "description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)", + "support": { + "issues": "https://github.com/phar-io/manifest/issues", + "source": "https://github.com/phar-io/manifest/tree/2.0.4" + }, + "funding": [ + { + "url": "https://github.com/theseer", + "type": "github" + } + ], + "time": "2024-03-03T12:33:53+00:00" + }, + { + "name": "phar-io/version", + "version": "3.2.1", + "source": { + "type": "git", + "url": "https://github.com/phar-io/version.git", + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phar-io/version/zipball/4f7fd7836c6f332bb2933569e566a0d6c4cbed74", + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74", + "shasum": "" + }, + "require": { + "php": "^7.2 || ^8.0" + }, + "type": "library", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Arne Blankerts", + "email": "arne@blankerts.de", + "role": "Developer" + }, + { + "name": "Sebastian Heuer", + "email": "sebastian@phpeople.de", + "role": "Developer" + }, + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "Developer" + } + ], + "description": "Library for handling version information and constraints", + "support": { + "issues": "https://github.com/phar-io/version/issues", + "source": "https://github.com/phar-io/version/tree/3.2.1" + }, + "time": "2022-02-21T01:04:05+00:00" + }, + { + "name": "phpstan/phpstan", + "version": "1.12.32", + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phpstan/phpstan/zipball/2770dcdf5078d0b0d53f94317e06affe88419aa8", + "reference": "2770dcdf5078d0b0d53f94317e06affe88419aa8", + "shasum": "" + }, + "require": { + "php": "^7.2|^8.0" + }, + "conflict": { + "phpstan/phpstan-shim": "*" + }, + "bin": [ + "phpstan", + "phpstan.phar" + ], + "type": "library", + "autoload": { + "files": [ + "bootstrap.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "PHPStan - PHP Static Analysis Tool", + "keywords": [ + "dev", + "static analysis" + ], + "support": { + "docs": "https://phpstan.org/user-guide/getting-started", + "forum": "https://github.com/phpstan/phpstan/discussions", + "issues": "https://github.com/phpstan/phpstan/issues", + "security": "https://github.com/phpstan/phpstan/security/policy", + "source": "https://github.com/phpstan/phpstan-src" + }, + "funding": [ + { + "url": "https://github.com/ondrejmirtes", + "type": "github" + }, + { + "url": "https://github.com/phpstan", + "type": "github" + } + ], + "time": "2025-09-30T10:16:31+00:00" + }, + { + "name": "phpunit/php-code-coverage", + "version": "9.2.32", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-code-coverage.git", + "reference": "85402a822d1ecf1db1096959413d35e1c37cf1a5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/85402a822d1ecf1db1096959413d35e1c37cf1a5", + "reference": "85402a822d1ecf1db1096959413d35e1c37cf1a5", + "shasum": "" + }, + "require": { + "ext-dom": "*", + "ext-libxml": "*", + "ext-xmlwriter": "*", + "nikic/php-parser": "^4.19.1 || ^5.1.0", + "php": ">=7.3", + "phpunit/php-file-iterator": "^3.0.6", + "phpunit/php-text-template": "^2.0.4", + "sebastian/code-unit-reverse-lookup": "^2.0.3", + "sebastian/complexity": "^2.0.3", + "sebastian/environment": "^5.1.5", + "sebastian/lines-of-code": "^1.0.4", + "sebastian/version": "^3.0.2", + "theseer/tokenizer": "^1.2.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.6" + }, + "suggest": { + "ext-pcov": "PHP extension that provides line coverage", + "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "9.2.x-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.", + "homepage": "https://github.com/sebastianbergmann/php-code-coverage", + "keywords": [ + "coverage", + "testing", + "xunit" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", + "security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy", + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.32" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2024-08-22T04:23:01+00:00" + }, + { + "name": "phpunit/php-file-iterator", + "version": "3.0.6", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-file-iterator.git", + "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", + "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "FilterIterator implementation that filters files based on a list of suffixes.", + "homepage": "https://github.com/sebastianbergmann/php-file-iterator/", + "keywords": [ + "filesystem", + "iterator" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.6" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2021-12-02T12:48:52+00:00" + }, + { + "name": "phpunit/php-invoker", + "version": "3.1.1", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-invoker.git", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/5a10147d0aaf65b58940a0b72f71c9ac0423cc67", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "ext-pcntl": "*", + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-pcntl": "*" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.1-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Invoke callables with a timeout", + "homepage": "https://github.com/sebastianbergmann/php-invoker/", + "keywords": [ + "process" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-invoker/issues", + "source": "https://github.com/sebastianbergmann/php-invoker/tree/3.1.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T05:58:55+00:00" + }, + { + "name": "phpunit/php-text-template", + "version": "2.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-text-template.git", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Simple template engine.", + "homepage": "https://github.com/sebastianbergmann/php-text-template/", + "keywords": [ + "template" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-text-template/issues", + "source": "https://github.com/sebastianbergmann/php-text-template/tree/2.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T05:33:50+00:00" + }, + { + "name": "phpunit/php-timer", + "version": "5.0.3", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-timer.git", + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "5.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Utility class for timing", + "homepage": "https://github.com/sebastianbergmann/php-timer/", + "keywords": [ + "timer" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-timer/issues", + "source": "https://github.com/sebastianbergmann/php-timer/tree/5.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:16:10+00:00" + }, + { + "name": "phpunit/phpunit", + "version": "9.6.31", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/phpunit.git", + "reference": "945d0b7f346a084ce5549e95289962972c4272e5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/945d0b7f346a084ce5549e95289962972c4272e5", + "reference": "945d0b7f346a084ce5549e95289962972c4272e5", + "shasum": "" + }, + "require": { + "doctrine/instantiator": "^1.5.0 || ^2", + "ext-dom": "*", + "ext-json": "*", + "ext-libxml": "*", + "ext-mbstring": "*", + "ext-xml": "*", + "ext-xmlwriter": "*", + "myclabs/deep-copy": "^1.13.4", + "phar-io/manifest": "^2.0.4", + "phar-io/version": "^3.2.1", + "php": ">=7.3", + "phpunit/php-code-coverage": "^9.2.32", + "phpunit/php-file-iterator": "^3.0.6", + "phpunit/php-invoker": "^3.1.1", + "phpunit/php-text-template": "^2.0.4", + "phpunit/php-timer": "^5.0.3", + "sebastian/cli-parser": "^1.0.2", + "sebastian/code-unit": "^1.0.8", + "sebastian/comparator": "^4.0.9", + "sebastian/diff": "^4.0.6", + "sebastian/environment": "^5.1.5", + "sebastian/exporter": "^4.0.8", + "sebastian/global-state": "^5.0.8", + "sebastian/object-enumerator": "^4.0.4", + "sebastian/resource-operations": "^3.0.4", + "sebastian/type": "^3.2.1", + "sebastian/version": "^3.0.2" + }, + "suggest": { + "ext-soap": "To be able to generate mocks based on WSDL files", + "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage" + }, + "bin": [ + "phpunit" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "9.6-dev" + } + }, + "autoload": { + "files": [ + "src/Framework/Assert/Functions.php" + ], + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "The PHP Unit Testing framework.", + "homepage": "https://phpunit.de/", + "keywords": [ + "phpunit", + "testing", + "xunit" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/phpunit/issues", + "security": "https://github.com/sebastianbergmann/phpunit/security/policy", + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.31" + }, + "funding": [ + { + "url": "https://phpunit.de/sponsors.html", + "type": "custom" + }, + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + }, + { + "url": "https://liberapay.com/sebastianbergmann", + "type": "liberapay" + }, + { + "url": "https://thanks.dev/u/gh/sebastianbergmann", + "type": "thanks_dev" + }, + { + "url": "https://tidelift.com/funding/github/packagist/phpunit/phpunit", + "type": "tidelift" + } + ], + "time": "2025-12-06T07:45:52+00:00" + }, + { + "name": "rector/rector", + "version": "1.2.10", + "source": { + "type": "git", + "url": "https://github.com/rectorphp/rector.git", + "reference": "40f9cf38c05296bd32f444121336a521a293fa61" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/rectorphp/rector/zipball/40f9cf38c05296bd32f444121336a521a293fa61", + "reference": "40f9cf38c05296bd32f444121336a521a293fa61", + "shasum": "" + }, + "require": { + "php": "^7.2|^8.0", + "phpstan/phpstan": "^1.12.5" + }, + "conflict": { + "rector/rector-doctrine": "*", + "rector/rector-downgrade-php": "*", + "rector/rector-phpunit": "*", + "rector/rector-symfony": "*" + }, + "suggest": { + "ext-dom": "To manipulate phpunit.xml via the custom-rule command" + }, + "bin": [ + "bin/rector" + ], + "type": "library", + "autoload": { + "files": [ + "bootstrap.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "Instant Upgrade and Automated Refactoring of any PHP code", + "keywords": [ + "automation", + "dev", + "migration", + "refactoring" + ], + "support": { + "issues": "https://github.com/rectorphp/rector/issues", + "source": "https://github.com/rectorphp/rector/tree/1.2.10" + }, + "funding": [ + { + "url": "https://github.com/tomasvotruba", + "type": "github" + } + ], + "time": "2024-11-08T13:59:10+00:00" + }, + { + "name": "sebastian/cli-parser", + "version": "1.0.2", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/cli-parser.git", + "reference": "2b56bea83a09de3ac06bb18b92f068e60cc6f50b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/2b56bea83a09de3ac06bb18b92f068e60cc6f50b", + "reference": "2b56bea83a09de3ac06bb18b92f068e60cc6f50b", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for parsing CLI options", + "homepage": "https://github.com/sebastianbergmann/cli-parser", + "support": { + "issues": "https://github.com/sebastianbergmann/cli-parser/issues", + "source": "https://github.com/sebastianbergmann/cli-parser/tree/1.0.2" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2024-03-02T06:27:43+00:00" + }, + { + "name": "sebastian/code-unit", + "version": "1.0.8", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit.git", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/1fc9f64c0927627ef78ba436c9b17d967e68e120", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Collection of value objects that represent the PHP code units", + "homepage": "https://github.com/sebastianbergmann/code-unit", + "support": { + "issues": "https://github.com/sebastianbergmann/code-unit/issues", + "source": "https://github.com/sebastianbergmann/code-unit/tree/1.0.8" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:08:54+00:00" + }, + { + "name": "sebastian/code-unit-reverse-lookup", + "version": "2.0.3", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Looks up which function or method a line of code belongs to", + "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", + "support": { + "issues": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/issues", + "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/2.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T05:30:19+00:00" + }, + { + "name": "sebastian/comparator", + "version": "4.0.9", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/comparator.git", + "reference": "67a2df3a62639eab2cc5906065e9805d4fd5dfc5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/67a2df3a62639eab2cc5906065e9805d4fd5dfc5", + "reference": "67a2df3a62639eab2cc5906065e9805d4fd5dfc5", + "shasum": "" + }, + "require": { + "php": ">=7.3", + "sebastian/diff": "^4.0", + "sebastian/exporter": "^4.0" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" + }, + { + "name": "Volker Dusch", + "email": "github@wallbash.com" + }, + { + "name": "Bernhard Schussek", + "email": "bschussek@2bepublished.at" + } + ], + "description": "Provides the functionality to compare PHP values for equality", + "homepage": "https://github.com/sebastianbergmann/comparator", + "keywords": [ + "comparator", + "compare", + "equality" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/comparator/issues", + "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.9" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + }, + { + "url": "https://liberapay.com/sebastianbergmann", + "type": "liberapay" + }, + { + "url": "https://thanks.dev/u/gh/sebastianbergmann", + "type": "thanks_dev" + }, + { + "url": "https://tidelift.com/funding/github/packagist/sebastian/comparator", + "type": "tidelift" + } + ], + "time": "2025-08-10T06:51:50+00:00" + }, + { + "name": "sebastian/complexity", + "version": "2.0.3", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/complexity.git", + "reference": "25f207c40d62b8b7aa32f5ab026c53561964053a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/25f207c40d62b8b7aa32f5ab026c53561964053a", + "reference": "25f207c40d62b8b7aa32f5ab026c53561964053a", + "shasum": "" + }, + "require": { + "nikic/php-parser": "^4.18 || ^5.0", + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for calculating the complexity of PHP code units", + "homepage": "https://github.com/sebastianbergmann/complexity", + "support": { + "issues": "https://github.com/sebastianbergmann/complexity/issues", + "source": "https://github.com/sebastianbergmann/complexity/tree/2.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-12-22T06:19:30+00:00" + }, + { + "name": "sebastian/diff", + "version": "4.0.6", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/diff.git", + "reference": "ba01945089c3a293b01ba9badc29ad55b106b0bc" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/ba01945089c3a293b01ba9badc29ad55b106b0bc", + "reference": "ba01945089c3a293b01ba9badc29ad55b106b0bc", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3", + "symfony/process": "^4.2 || ^5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Kore Nordmann", + "email": "mail@kore-nordmann.de" + } + ], + "description": "Diff implementation", + "homepage": "https://github.com/sebastianbergmann/diff", + "keywords": [ + "diff", + "udiff", + "unidiff", + "unified diff" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/diff/issues", + "source": "https://github.com/sebastianbergmann/diff/tree/4.0.6" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2024-03-02T06:30:58+00:00" + }, + { + "name": "sebastian/environment", + "version": "5.1.5", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/environment.git", + "reference": "830c43a844f1f8d5b7a1f6d6076b784454d8b7ed" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/830c43a844f1f8d5b7a1f6d6076b784454d8b7ed", + "reference": "830c43a844f1f8d5b7a1f6d6076b784454d8b7ed", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-posix": "*" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "5.1-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Provides functionality to handle HHVM/PHP environments", + "homepage": "http://www.github.com/sebastianbergmann/environment", + "keywords": [ + "Xdebug", + "environment", + "hhvm" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/environment/issues", + "source": "https://github.com/sebastianbergmann/environment/tree/5.1.5" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T06:03:51+00:00" + }, + { + "name": "sebastian/exporter", + "version": "4.0.8", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/exporter.git", + "reference": "14c6ba52f95a36c3d27c835d65efc7123c446e8c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/14c6ba52f95a36c3d27c835d65efc7123c446e8c", + "reference": "14c6ba52f95a36c3d27c835d65efc7123c446e8c", + "shasum": "" + }, + "require": { + "php": ">=7.3", + "sebastian/recursion-context": "^4.0" + }, + "require-dev": { + "ext-mbstring": "*", + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" + }, + { + "name": "Volker Dusch", + "email": "github@wallbash.com" + }, + { + "name": "Adam Harvey", + "email": "aharvey@php.net" + }, + { + "name": "Bernhard Schussek", + "email": "bschussek@gmail.com" + } + ], + "description": "Provides the functionality to export PHP variables for visualization", + "homepage": "https://www.github.com/sebastianbergmann/exporter", + "keywords": [ + "export", + "exporter" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/exporter/issues", + "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.8" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + }, + { + "url": "https://liberapay.com/sebastianbergmann", + "type": "liberapay" + }, + { + "url": "https://thanks.dev/u/gh/sebastianbergmann", + "type": "thanks_dev" + }, + { + "url": "https://tidelift.com/funding/github/packagist/sebastian/exporter", + "type": "tidelift" + } + ], + "time": "2025-09-24T06:03:27+00:00" + }, + { + "name": "sebastian/global-state", + "version": "5.0.8", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/global-state.git", + "reference": "b6781316bdcd28260904e7cc18ec983d0d2ef4f6" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/b6781316bdcd28260904e7cc18ec983d0d2ef4f6", + "reference": "b6781316bdcd28260904e7cc18ec983d0d2ef4f6", + "shasum": "" + }, + "require": { + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" + }, + "require-dev": { + "ext-dom": "*", + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-uopz": "*" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "5.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Snapshotting of global state", + "homepage": "http://www.github.com/sebastianbergmann/global-state", + "keywords": [ + "global state" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/global-state/issues", + "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.8" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + }, + { + "url": "https://liberapay.com/sebastianbergmann", + "type": "liberapay" + }, + { + "url": "https://thanks.dev/u/gh/sebastianbergmann", + "type": "thanks_dev" + }, + { + "url": "https://tidelift.com/funding/github/packagist/sebastian/global-state", + "type": "tidelift" + } + ], + "time": "2025-08-10T07:10:35+00:00" + }, + { + "name": "sebastian/lines-of-code", + "version": "1.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/lines-of-code.git", + "reference": "e1e4a170560925c26d424b6a03aed157e7dcc5c5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/e1e4a170560925c26d424b6a03aed157e7dcc5c5", + "reference": "e1e4a170560925c26d424b6a03aed157e7dcc5c5", + "shasum": "" + }, + "require": { + "nikic/php-parser": "^4.18 || ^5.0", + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for counting the lines of code in PHP source code", + "homepage": "https://github.com/sebastianbergmann/lines-of-code", + "support": { + "issues": "https://github.com/sebastianbergmann/lines-of-code/issues", + "source": "https://github.com/sebastianbergmann/lines-of-code/tree/1.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-12-22T06:20:34+00:00" + }, + { + "name": "sebastian/object-enumerator", + "version": "4.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/object-enumerator.git", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/5c9eeac41b290a3712d88851518825ad78f45c71", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71", + "shasum": "" + }, + "require": { + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Traverses array structures and object graphs to enumerate all referenced objects", + "homepage": "https://github.com/sebastianbergmann/object-enumerator/", + "support": { + "issues": "https://github.com/sebastianbergmann/object-enumerator/issues", + "source": "https://github.com/sebastianbergmann/object-enumerator/tree/4.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:12:34+00:00" + }, + { + "name": "sebastian/object-reflector", + "version": "2.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/object-reflector.git", + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Allows reflection of object attributes, including inherited and non-public ones", + "homepage": "https://github.com/sebastianbergmann/object-reflector/", + "support": { + "issues": "https://github.com/sebastianbergmann/object-reflector/issues", + "source": "https://github.com/sebastianbergmann/object-reflector/tree/2.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:14:26+00:00" + }, + { + "name": "sebastian/recursion-context", + "version": "4.0.6", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/recursion-context.git", + "reference": "539c6691e0623af6dc6f9c20384c120f963465a0" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/539c6691e0623af6dc6f9c20384c120f963465a0", + "reference": "539c6691e0623af6dc6f9c20384c120f963465a0", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" + }, + { + "name": "Adam Harvey", + "email": "aharvey@php.net" + } + ], + "description": "Provides functionality to recursively process PHP variables", + "homepage": "https://github.com/sebastianbergmann/recursion-context", + "support": { + "issues": "https://github.com/sebastianbergmann/recursion-context/issues", + "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.6" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + }, + { + "url": "https://liberapay.com/sebastianbergmann", + "type": "liberapay" + }, + { + "url": "https://thanks.dev/u/gh/sebastianbergmann", + "type": "thanks_dev" + }, + { + "url": "https://tidelift.com/funding/github/packagist/sebastian/recursion-context", + "type": "tidelift" + } + ], + "time": "2025-08-10T06:57:39+00:00" + }, + { + "name": "sebastian/resource-operations", + "version": "3.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/resource-operations.git", + "reference": "05d5692a7993ecccd56a03e40cd7e5b09b1d404e" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/05d5692a7993ecccd56a03e40cd7e5b09b1d404e", + "reference": "05d5692a7993ecccd56a03e40cd7e5b09b1d404e", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "3.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Provides a list of PHP built-in functions that operate on resources", + "homepage": "https://www.github.com/sebastianbergmann/resource-operations", + "support": { + "source": "https://github.com/sebastianbergmann/resource-operations/tree/3.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2024-03-14T16:00:52+00:00" + }, + { + "name": "sebastian/type", + "version": "3.2.1", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/type.git", + "reference": "75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7", + "reference": "75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.2-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Collection of value objects that represent the types of the PHP type system", + "homepage": "https://github.com/sebastianbergmann/type", + "support": { + "issues": "https://github.com/sebastianbergmann/type/issues", + "source": "https://github.com/sebastianbergmann/type/tree/3.2.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-02-03T06:13:03+00:00" + }, + { + "name": "sebastian/version", + "version": "3.0.2", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/version.git", + "reference": "c6c1022351a901512170118436c764e473f6de8c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c6c1022351a901512170118436c764e473f6de8c", + "reference": "c6c1022351a901512170118436c764e473f6de8c", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library that helps with managing the version number of Git-hosted PHP projects", + "homepage": "https://github.com/sebastianbergmann/version", + "support": { + "issues": "https://github.com/sebastianbergmann/version/issues", + "source": "https://github.com/sebastianbergmann/version/tree/3.0.2" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T06:39:44+00:00" + }, + { + "name": "symfony/console", + "version": "v8.0.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/console.git", + "reference": "fcb73f69d655b48fcb894a262f074218df08bd58" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/console/zipball/fcb73f69d655b48fcb894a262f074218df08bd58", + "reference": "fcb73f69d655b48fcb894a262f074218df08bd58", + "shasum": "" + }, + "require": { + "php": ">=8.4", + "symfony/polyfill-mbstring": "^1.0", + "symfony/service-contracts": "^2.5|^3", + "symfony/string": "^7.4|^8.0" + }, + "provide": { + "psr/log-implementation": "1.0|2.0|3.0" + }, + "require-dev": { + "psr/log": "^1|^2|^3", + "symfony/config": "^7.4|^8.0", + "symfony/dependency-injection": "^7.4|^8.0", + "symfony/event-dispatcher": "^7.4|^8.0", + "symfony/http-foundation": "^7.4|^8.0", + "symfony/http-kernel": "^7.4|^8.0", + "symfony/lock": "^7.4|^8.0", + "symfony/messenger": "^7.4|^8.0", + "symfony/process": "^7.4|^8.0", + "symfony/stopwatch": "^7.4|^8.0", + "symfony/var-dumper": "^7.4|^8.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\Console\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Eases the creation of beautiful and testable command line interfaces", + "homepage": "https://symfony.com", + "keywords": [ + "cli", + "command-line", + "console", + "terminal" + ], + "support": { + "source": "https://github.com/symfony/console/tree/v8.0.1" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2025-12-05T15:25:33+00:00" + }, + { + "name": "symfony/http-client", + "version": "v8.0.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/http-client.git", + "reference": "727fda60d0aebfdfcc4c8bc4661f0cb8f44153c0" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/http-client/zipball/727fda60d0aebfdfcc4c8bc4661f0cb8f44153c0", + "reference": "727fda60d0aebfdfcc4c8bc4661f0cb8f44153c0", + "shasum": "" + }, + "require": { + "php": ">=8.4", + "psr/log": "^1|^2|^3", + "symfony/http-client-contracts": "~3.4.4|^3.5.2", + "symfony/service-contracts": "^2.5|^3" + }, + "conflict": { + "amphp/amp": "<3", + "php-http/discovery": "<1.15" + }, + "provide": { + "php-http/async-client-implementation": "*", + "php-http/client-implementation": "*", + "psr/http-client-implementation": "1.0", + "symfony/http-client-implementation": "3.0" + }, + "require-dev": { + "amphp/http-client": "^5.3.2", + "amphp/http-tunnel": "^2.0", + "guzzlehttp/promises": "^1.4|^2.0", + "nyholm/psr7": "^1.0", + "php-http/httplug": "^1.0|^2.0", + "psr/http-client": "^1.0", + "symfony/cache": "^7.4|^8.0", + "symfony/dependency-injection": "^7.4|^8.0", + "symfony/http-kernel": "^7.4|^8.0", + "symfony/messenger": "^7.4|^8.0", + "symfony/process": "^7.4|^8.0", + "symfony/rate-limiter": "^7.4|^8.0", + "symfony/stopwatch": "^7.4|^8.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Symfony\\Component\\HttpClient\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides powerful methods to fetch HTTP resources synchronously or asynchronously", + "homepage": "https://symfony.com", + "keywords": [ + "http" + ], + "support": { + "source": "https://github.com/symfony/http-client/tree/v8.0.1" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2025-12-05T14:08:45+00:00" + }, + { + "name": "symfony/http-client-contracts", + "version": "v3.6.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/http-client-contracts.git", + "reference": "75d7043853a42837e68111812f4d964b01e5101c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/http-client-contracts/zipball/75d7043853a42837e68111812f4d964b01e5101c", + "reference": "75d7043853a42837e68111812f4d964b01e5101c", + "shasum": "" + }, + "require": { + "php": ">=8.1" + }, + "type": "library", + "extra": { + "thanks": { + "url": "https://github.com/symfony/contracts", + "name": "symfony/contracts" + }, + "branch-alias": { + "dev-main": "3.6-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Contracts\\HttpClient\\": "" + }, + "exclude-from-classmap": [ + "/Test/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Generic abstractions related to HTTP clients", + "homepage": "https://symfony.com", + "keywords": [ + "abstractions", + "contracts", + "decoupling", + "interfaces", + "interoperability", + "standards" + ], + "support": { + "source": "https://github.com/symfony/http-client-contracts/tree/v3.6.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2025-04-29T11:18:49+00:00" + }, + { + "name": "symfony/polyfill-intl-grapheme", + "version": "v1.33.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-intl-grapheme.git", + "reference": "380872130d3a5dd3ace2f4010d95125fde5d5c70" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/380872130d3a5dd3ace2f4010d95125fde5d5c70", + "reference": "380872130d3a5dd3ace2f4010d95125fde5d5c70", + "shasum": "" + }, + "require": { + "php": ">=7.2" + }, + "suggest": { + "ext-intl": "For best performance" + }, + "type": "library", + "extra": { + "thanks": { + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Intl\\Grapheme\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for intl's grapheme_* functions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "grapheme", + "intl", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.33.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2025-06-27T09:58:17+00:00" + }, + { + "name": "symfony/polyfill-intl-normalizer", + "version": "v1.33.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-intl-normalizer.git", + "reference": "3833d7255cc303546435cb650316bff708a1c75c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/3833d7255cc303546435cb650316bff708a1c75c", + "reference": "3833d7255cc303546435cb650316bff708a1c75c", + "shasum": "" + }, + "require": { + "php": ">=7.2" + }, + "suggest": { + "ext-intl": "For best performance" + }, + "type": "library", + "extra": { + "thanks": { + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Intl\\Normalizer\\": "" + }, + "classmap": [ + "Resources/stubs" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for intl's Normalizer class and related functions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "intl", + "normalizer", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.33.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-09-09T11:45:10+00:00" + }, + { + "name": "symfony/string", + "version": "v8.0.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/string.git", + "reference": "ba65a969ac918ce0cc3edfac6cdde847eba231dc" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/string/zipball/ba65a969ac918ce0cc3edfac6cdde847eba231dc", + "reference": "ba65a969ac918ce0cc3edfac6cdde847eba231dc", + "shasum": "" + }, + "require": { + "php": ">=8.4", + "symfony/polyfill-ctype": "^1.8", + "symfony/polyfill-intl-grapheme": "^1.33", + "symfony/polyfill-intl-normalizer": "^1.0", + "symfony/polyfill-mbstring": "^1.0" + }, + "conflict": { + "symfony/translation-contracts": "<2.5" + }, + "require-dev": { + "symfony/emoji": "^7.4|^8.0", + "symfony/http-client": "^7.4|^8.0", + "symfony/intl": "^7.4|^8.0", + "symfony/translation-contracts": "^2.5|^3.0", + "symfony/var-exporter": "^7.4|^8.0" + }, + "type": "library", + "autoload": { + "files": [ + "Resources/functions.php" + ], + "psr-4": { + "Symfony\\Component\\String\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Provides an object-oriented API to strings and deals with bytes, UTF-8 code points and grapheme clusters in a unified way", + "homepage": "https://symfony.com", + "keywords": [ + "grapheme", + "i18n", + "string", + "unicode", + "utf-8", + "utf8" + ], + "support": { + "source": "https://github.com/symfony/string/tree/v8.0.1" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2025-12-01T09:13:36+00:00" + }, + { + "name": "theseer/tokenizer", + "version": "1.3.1", + "source": { + "type": "git", + "url": "https://github.com/theseer/tokenizer.git", + "reference": "b7489ce515e168639d17feec34b8847c326b0b3c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/theseer/tokenizer/zipball/b7489ce515e168639d17feec34b8847c326b0b3c", + "reference": "b7489ce515e168639d17feec34b8847c326b0b3c", + "shasum": "" + }, + "require": { + "ext-dom": "*", + "ext-tokenizer": "*", + "ext-xmlwriter": "*", + "php": "^7.2 || ^8.0" + }, + "type": "library", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Arne Blankerts", + "email": "arne@blankerts.de", + "role": "Developer" + } + ], + "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", + "support": { + "issues": "https://github.com/theseer/tokenizer/issues", + "source": "https://github.com/theseer/tokenizer/tree/1.3.1" + }, + "funding": [ + { + "url": "https://github.com/theseer", + "type": "github" + } + ], + "time": "2025-11-17T20:03:58+00:00" + } + ], + "aliases": [], + "minimum-stability": "stable", + "stability-flags": {}, + "prefer-stable": false, + "prefer-lowest": false, + "platform": { + "php": ">=8.4" + }, + "platform-dev": {}, + "plugin-api-version": "2.9.0" +} diff --git a/old-docs/examples/00-describe/01-csv-transform.php b/old-docs/examples/00-describe/01-csv-transform.php index 10c25f2..32947e9 100644 --- a/old-docs/examples/00-describe/01-csv-transform.php +++ b/old-docs/examples/00-describe/01-csv-transform.php @@ -10,7 +10,7 @@ $chainProcessor->process( new ArrayIterator(["/customers.csv"]), [], - function (array $operationStates, int $itemsProcessed, int $itemsReturned, bool $hasEnded) use ($symfonyOutput) { + function (array $operationStates, int $itemsProcessed, int $itemsReturned, bool $hasEnded) use ($symfonyOutput): void { $symfonyOutput->output($operationStates, $hasEnded); } ); diff --git a/old-docs/examples/00-describe/05-csv-3-files.php b/old-docs/examples/00-describe/05-csv-3-files.php index 81fa2b4..d59b276 100644 --- a/old-docs/examples/00-describe/05-csv-3-files.php +++ b/old-docs/examples/00-describe/05-csv-3-files.php @@ -10,7 +10,7 @@ $chainProcessor->process( new ArrayIterator(["/customers.csv", "/customers2.csv"]), [], - function (array $operationStates, int $itemsProcessed, int $itemsReturned, bool $hasEnded) use ($symfonyOutput) { + function (array $operationStates, int $itemsProcessed, int $itemsReturned, bool $hasEnded) use ($symfonyOutput): void { $symfonyOutput->output($operationStates, $hasEnded); // Just so that the output is nicer. usleep(100000); diff --git a/old-docs/examples/00-describe/09-api-to-csv2.php b/old-docs/examples/00-describe/09-api-to-csv2.php index f9f9796..4be0a28 100644 --- a/old-docs/examples/00-describe/09-api-to-csv2.php +++ b/old-docs/examples/00-describe/09-api-to-csv2.php @@ -31,7 +31,7 @@ ["id"=> 19], ]), [], - function (array $operationStates, int $itemsProcessed, int $itemsReturned, bool $hasEnded) use ($symfonyOutput) { + function (array $operationStates, int $itemsProcessed, int $itemsReturned, bool $hasEnded) use ($symfonyOutput): void { $symfonyOutput->output($operationStates, $hasEnded); } ); diff --git a/old-docs/examples/01-describe/01-subchain.php b/old-docs/examples/01-describe/01-subchain.php index 720cf6e..a9770d8 100644 --- a/old-docs/examples/01-describe/01-subchain.php +++ b/old-docs/examples/01-describe/01-subchain.php @@ -10,7 +10,7 @@ $chainProcessor->process( new ArrayIterator([getProcessFilePath(__DIR__, "/customers.csv")]), [], - function (array $operationStates, int $itemsProcessed, int $itemsReturned, bool $hasEnded) use ($symfonyOutput) { + function (array $operationStates, int $itemsProcessed, int $itemsReturned, bool $hasEnded) use ($symfonyOutput): void { $symfonyOutput->output($operationStates, $hasEnded); // Slow down to make output more "interesting". usleep(500000); diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/AbstractFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/AbstractFactory.php index 031b58f..936cbd4 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/AbstractFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/AbstractFactory.php @@ -74,10 +74,9 @@ protected function configureValidator(): Constraint } /** - * @param mixed ...$arguments * @return ChainOperationInterface */ - protected function create(...$arguments): ChainOperationInterface + protected function create(mixed ...$arguments): ChainOperationInterface { $class = $this->class; return new $class(...$arguments); diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/ChainRepeatFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/ChainRepeatFactory.php index 660bd65..6a565a0 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/ChainRepeatFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/ChainRepeatFactory.php @@ -15,6 +15,7 @@ public function __construct(string $operation, string $class, protected readonly parent::__construct($operation, $class); } + #[\Override] public function build(string $operation, array $options): ChainOperationInterface { $maxAsync = $options['maxASynchronousItems'] ?? 0; @@ -25,6 +26,7 @@ public function build(string $operation, array $options): ChainOperationInterfac return $this->create($chainProcessor, $options['validationExpr'], $allowAsync); } + #[\Override] protected function configureValidator(): Constraint { return new Assert\Collection([ diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/ChainSplitFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/ChainSplitFactory.php index 3230c20..3aebee3 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/ChainSplitFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/ChainSplitFactory.php @@ -21,6 +21,7 @@ public function __construct(string $operation, string $class, ChainBuilder $buil /** * @inheritdoc */ + #[\Override] public function build(string $operation, array $options): ChainOperationInterface { $chainProcessors = []; @@ -31,6 +32,7 @@ public function build(string $operation, array $options): ChainOperationInterfac return $this->create($chainProcessors); } + #[\Override] protected function configureValidator(): Constraint { return new Assert\Collection([ diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Extract/CsvExtractFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Extract/CsvExtractFactory.php index d92103f..105a8d8 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Extract/CsvExtractFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Extract/CsvExtractFactory.php @@ -9,6 +9,7 @@ class CsvExtractFactory extends AbstractFactory { + #[\Override] protected function build(string $operation, array $options): ChainOperationInterface { return $this->create( diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Extract/ExternalFileFinderFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Extract/ExternalFileFinderFactory.php index 1ef7732..3ba5e3f 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Extract/ExternalFileFinderFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Extract/ExternalFileFinderFactory.php @@ -11,20 +11,19 @@ class ExternalFileFinderFactory extends AbstractFactory { - protected FileSystemInterface $fileSystem; - - public function __construct(string $operation, string $class, FileSystemInterface $fileSystem) + public function __construct(string $operation, string $class, protected FileSystemInterface $fileSystem) { parent::__construct($operation, $class); - $this->fileSystem = $fileSystem; } + #[\Override] protected function build(string $operation, array $options): ChainOperationInterface { return $this->create($this->fileSystem, $options['directory']); } + #[\Override] protected function configureValidator(): Constraint { return new Assert\Collection([ diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Extract/JsonExtractFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Extract/JsonExtractFactory.php index 9403ce8..c8fde5d 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Extract/JsonExtractFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Extract/JsonExtractFactory.php @@ -7,6 +7,7 @@ class JsonExtractFactory extends AbstractFactory { + #[\Override] protected function build(string $operation, array $options): ChainOperationInterface { return $this->create($options['fileKey'] ?? 'file', $options['scoped'] ?? true); diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Grouping/SimpleGroupingFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Grouping/SimpleGroupingFactory.php index 842c18d..4e0d49e 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Grouping/SimpleGroupingFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Grouping/SimpleGroupingFactory.php @@ -21,6 +21,7 @@ class SimpleGroupingFactory extends AbstractFactory /** * @inheritdoc */ + #[\Override] public function build(string $operation, array $options): ChainOperationInterface { return $this->create($options['grouping-key'], $options['group-identifier']); @@ -29,6 +30,7 @@ public function build(string $operation, array $options): ChainOperationInterfac /** * @inheritdoc */ + #[\Override] protected function configureValidator(): Constraint { return new Assert\Collection([ diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Loader/CsvFileWriterFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Loader/CsvFileWriterFactory.php index 5ee4dc5..97990b7 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Loader/CsvFileWriterFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Loader/CsvFileWriterFactory.php @@ -22,6 +22,7 @@ class CsvFileWriterFactory extends AbstractFactory /** * @inheritdoc */ + #[\Override] protected function configureValidator(): Constraint { return new Assert\Collection([ @@ -32,6 +33,7 @@ protected function configureValidator(): Constraint /** * @inheritdoc */ + #[\Override] protected function build($operation, $options): ChainOperationInterface { $tmp = tempnam(sys_get_temp_dir(), 'etl'); diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Loader/JsonFileWriterFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Loader/JsonFileWriterFactory.php index 584085a..484c1d3 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Loader/JsonFileWriterFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Loader/JsonFileWriterFactory.php @@ -22,6 +22,7 @@ class JsonFileWriterFactory extends AbstractFactory /** * @inheritdoc */ + #[\Override] protected function configureValidator(): Constraint { return new Assert\Collection([ @@ -32,6 +33,7 @@ protected function configureValidator(): Constraint /** * @inheritdoc */ + #[\Override] protected function build($operation, $options): ChainOperationInterface { $tmp = tempnam(sys_get_temp_dir(), 'etl'); diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/ExternalFileProcessorFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/ExternalFileProcessorFactory.php index 073f441..c69c910 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/ExternalFileProcessorFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/ExternalFileProcessorFactory.php @@ -9,6 +9,7 @@ class ExternalFileProcessorFactory extends AbstractFactory { + #[\Override] protected function build(string $operation, array $options): ChainOperationInterface { return $this->create(); diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/FilterDataFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/FilterDataFactory.php index cba7bb1..16637fc 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/FilterDataFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/FilterDataFactory.php @@ -38,6 +38,7 @@ public function __construct(string $operation, string $class, RuleApplier $ruleA /** * @inheritdoc */ + #[\Override] public function build(string $operation, array $options): ChainOperationInterface { return $this->create($this->ruleApplier, $options['rule'], $options['negate']); @@ -46,6 +47,7 @@ public function build(string $operation, array $options): ChainOperationInterfac /** * @inheritdoc */ + #[\Override] protected function configureValidator(): Constraint { return new Assert\Collection([ diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/LogFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/LogFactory.php index 9b1f8f1..d4c124b 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/LogFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/LogFactory.php @@ -17,11 +17,13 @@ public function __construct(string $operation, string $class) parent::__construct($operation, $class); } + #[\Override] protected function build($operation, $options): ChainOperationInterface { return $this->create($options['message'], $options['level'], $options['context'] ?? []); } + #[\Override] protected function configureValidator(): Constraint { return new Assert\Collection([ diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/RuleTransformFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/RuleTransformFactory.php index dc555ad..4751882 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/RuleTransformFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/RuleTransformFactory.php @@ -38,6 +38,7 @@ public function __construct(string $operation, string $class, RuleApplier $ruleA /** * @inheritdoc */ + #[\Override] public function build(string $operation, array $options): ChainOperationInterface { return $this->create($this->ruleApplier, $options['columns'], $options['add']); @@ -46,6 +47,7 @@ public function build(string $operation, array $options): ChainOperationInterfac /** * @inheritdoc */ + #[\Override] protected function configureValidator(): Constraint { return new Assert\Collection([ diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/SimpleHttpOperationFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/SimpleHttpOperationFactory.php index 04d5cfb..a59f5c8 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/SimpleHttpOperationFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/SimpleHttpOperationFactory.php @@ -13,6 +13,7 @@ class SimpleHttpOperationFactory extends AbstractFactory { + #[\Override] protected function build(string $operation, array $options): ChainOperationInterface { if (!class_exists(HttpClient::class)) { @@ -31,6 +32,7 @@ protected function build(string $operation, array $options): ChainOperationInter ); } + #[\Override] protected function configureValidator(): Constraint { return new Assert\Collection([ diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/SimpleHttpOperationWithClientFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/SimpleHttpOperationWithClientFactory.php index 10e2064..a61cec9 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/SimpleHttpOperationWithClientFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/SimpleHttpOperationWithClientFactory.php @@ -12,18 +12,15 @@ class SimpleHttpOperationWithClientFactory extends AbstractFactory { - private HttpClientInterface $httpClient; - /** * @param HttpClientInterface $httpClient */ - public function __construct(string $operation, HttpClientInterface $httpClient) + public function __construct(string $operation, private readonly HttpClientInterface $httpClient) { - $this->httpClient = $httpClient; - parent::__construct($operation, SimpleHttpOperation::class); } + #[\Override] protected function build(string $operation, array $options): ChainOperationInterface { return new SimpleHttpOperation( @@ -36,6 +33,7 @@ protected function build(string $operation, array $options): ChainOperationInter ); } + #[\Override] protected function configureValidator(): Constraint { return new Assert\Collection([ diff --git a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/SplitItemFactory.php b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/SplitItemFactory.php index e007958..fa4b3bf 100644 --- a/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/SplitItemFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Builder/Factories/Transformer/SplitItemFactory.php @@ -26,6 +26,7 @@ public function __construct(string $operation, string $class) /** * @inheritdoc */ + #[\Override] public function build(string $operation, array $options): ChainOperationInterface { return $this->create( @@ -40,6 +41,7 @@ public function build(string $operation, array $options): ChainOperationInterfac /** * @inheritdoc */ + #[\Override] protected function configureValidator(): Constraint { return new Assert\Collection( diff --git a/src/Oliverde8/Component/PhpEtl/ChainBuilder.php b/src/Oliverde8/Component/PhpEtl/ChainBuilder.php index 8a292a7..08fcf57 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainBuilder.php +++ b/src/Oliverde8/Component/PhpEtl/ChainBuilder.php @@ -25,17 +25,13 @@ class ChainBuilder /** @var ChainProcessor[] */ protected array $subChainProcessors = []; - protected ExecutionContextFactoryInterface $contextFactory; - protected ExpressionLanguage $expressionLanguage; /** * @param ExecutionContextFactoryInterface $contextFactory */ - public function __construct(ExecutionContextFactoryInterface $contextFactory) + public function __construct(protected ExecutionContextFactoryInterface $contextFactory) { - $this->contextFactory = $contextFactory; - $this->expressionLanguage = new ExpressionLanguage(); } @@ -70,7 +66,7 @@ public function buildChainProcessor(array $configs, array $inputOptions = [], in foreach ($configs['subChains'] ?? [] as $subChainName => $subChainConfigs) { $chainOperations = []; foreach ($subChainConfigs['chain'] as $id => $operation) { - $chainOperations[$id] = $this->getOperationFromConfig($operation, $inputOptions, $subChainProcessors); + $chainOperations[$id] = $this->getOperationFromConfig($operation, $inputOptions); } $this->subChainProcessors[$subChainName] = new ChainProcessor( $chainOperations, @@ -97,13 +93,13 @@ public function buildChainProcessor(array $configs, array $inputOptions = [], in protected function getOperationFromConfig(array $config, array $inputOptions): ChainOperationInterface { foreach ($config['options'] as &$option) { - if (is_string($option) && strpos($option, "!") === 0) { + if (is_string($option) && str_starts_with($option, "!")) { $option = ltrim($option, '!'); $option = $this->expressionLanguage->evaluate($option, $inputOptions); } } - if (strtolower($config['operation']) == 'subchain') { + if (strtolower((string) $config['operation']) == 'subchain') { $subChain = $config['options']['name']; if (!isset($this->subChainProcessors[$subChain])) { throw new UnknownOperationException("No subchain '$subChain' was found to create operation"); diff --git a/src/Oliverde8/Component/PhpEtl/ChainObserver/ChainObserver.php b/src/Oliverde8/Component/PhpEtl/ChainObserver/ChainObserver.php index db6128b..0985d56 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainObserver/ChainObserver.php +++ b/src/Oliverde8/Component/PhpEtl/ChainObserver/ChainObserver.php @@ -24,6 +24,7 @@ public function __construct(callable $closure) } + #[\Override] public function init(array $chainLinks, array $chainNames): void { foreach ($chainLinks as $id => $operation) { @@ -33,6 +34,7 @@ public function init(array $chainLinks, array $chainNames): void $this->callback(); } + #[\Override] public function onBeforeProcess($operationId, ChainOperationInterface $operation, ItemInterface $item): void { $this->ended = false; @@ -42,6 +44,7 @@ public function onBeforeProcess($operationId, ChainOperationInterface $operation $this->callback(); } + #[\Override] public function onAfterProcess($operationId, ChainOperationInterface $operation, ItemInterface $item): void { $this->returnItem($operation, $item); @@ -50,6 +53,7 @@ public function onAfterProcess($operationId, ChainOperationInterface $operation, $this->callback(); } + #[\Override] public function onFinish() { $this->ended = true; diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/AbstractChainOperation.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/AbstractChainOperation.php index b87f847..d763dc7 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/AbstractChainOperation.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/AbstractChainOperation.php @@ -23,12 +23,13 @@ abstract class AbstractChainOperation implements ChainOperationInterface /** * @inheritdoc */ + #[\Override] final public function process(ItemInterface $item, ExecutionContext $context): ItemInterface { - if (!isset($this->methodResolutionCache[get_class($item)])) { - $this->methodResolutionCache[get_class($item)] = $this->resolveMethodName($item); + if (!isset($this->methodResolutionCache[$item::class])) { + $this->methodResolutionCache[$item::class] = $this->resolveMethodName($item); } - $method = $this->methodResolutionCache[get_class($item)]; + $method = $this->methodResolutionCache[$item::class]; if (!is_null($method)) { return $this->$method($item, $context); @@ -53,7 +54,7 @@ private function resolveMethodName(ItemInterface $item): ?string continue; } - if ($this->checkIsA(get_class($item), $expecting)) { + if ($this->checkIsA($item::class, $expecting)) { return $method->getName(); } }; @@ -85,7 +86,7 @@ private function validateMethod(\ReflectionMethod $method) if (in_array($method->getName(), ['process', 'resolveMethodName'])) { return false; } - if (strpos($method->getName(), "process") !== 0) { + if (!str_starts_with($method->getName(), "process")) { return false; } diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/ChainMergeOperation.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/ChainMergeOperation.php index f6c1d3a..f447a01 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/ChainMergeOperation.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/ChainMergeOperation.php @@ -22,20 +22,17 @@ class ChainMergeOperation extends AbstractChainOperation implements DataChainOpe { use SplittedChainOperationTrait; - /** @var ChainProcessor[] */ - protected array $chainProcessors; - /** * ChainSplitOperation constructor. * * @param ChainProcessor[] $chainProcessors */ - public function __construct(array $chainProcessors) + public function __construct(protected array $chainProcessors) { - $this->chainProcessors = $chainProcessors; - $this->onSplittedChainOperationConstruct($chainProcessors); + $this->onSplittedChainOperationConstruct($this->chainProcessors); } + #[\Override] public function processData(DataItemInterface $item, ExecutionContext $context): ItemInterface { $returnItems = []; diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/ChainSplitOperation.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/ChainSplitOperation.php index 5e519ae..90ceeb8 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/ChainSplitOperation.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/ChainSplitOperation.php @@ -22,22 +22,17 @@ class ChainSplitOperation extends AbstractChainOperation implements DataChainOpe { use SplittedChainOperationTrait; - /** - * @var ChainProcessor[] - */ - private array $chainProcessors; - /** * ChainSplitOperation constructor. * * @param ChainProcessor[] $chainProcessors */ - public function __construct(array $chainProcessors) + public function __construct(private array $chainProcessors) { - $this->chainProcessors = $chainProcessors; - $this->onSplittedChainOperationConstruct($chainProcessors); + $this->onSplittedChainOperationConstruct($this->chainProcessors); } + #[\Override] public function processData(DataItemInterface $item, ExecutionContext $context): ItemInterface { foreach ($this->chainProcessors as $chainProcessor) { diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/Extract/CsvExtractOperation.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/Extract/CsvExtractOperation.php index 17d5d56..4436861 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/Extract/CsvExtractOperation.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/Extract/CsvExtractOperation.php @@ -15,26 +15,12 @@ class CsvExtractOperation extends AbstractChainOperation implements DataChainOperationInterface { - protected string $delimiter; - - protected string $enclosure; - - protected string $escape; - - protected string $fileKey; - - protected bool $scoped; - - public function __construct(string $delimiter, string $enclosure, string $escape, string $fileKey, bool $scoped) + public function __construct(protected string $delimiter, protected string $enclosure, protected string $escape, protected string $fileKey, protected bool $scoped) { - $this->delimiter = $delimiter; - $this->enclosure = $enclosure; - $this->escape = $escape; - $this->fileKey = $fileKey; - $this->scoped = $scoped; } + #[\Override] public function processData(DataItemInterface $item, ExecutionContext $context): ItemInterface { $filename = $item->getData(); diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/Extract/ExternalFileFinderOperation.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/Extract/ExternalFileFinderOperation.php index dd9626b..7aea073 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/Extract/ExternalFileFinderOperation.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/Extract/ExternalFileFinderOperation.php @@ -15,35 +15,29 @@ class ExternalFileFinderOperation extends AbstractChainOperation implements DataChainOperationInterface { - protected FileSystemInterface $fileSystem; + private readonly ExpressionLanguage $expressionLanguage; - protected string $directory; - private ExpressionLanguage $expressionLanguage; - - - public function __construct(FileSystemInterface $fileSystem, string $directory) + public function __construct(protected FileSystemInterface $fileSystem, protected string $directory) { - $this->fileSystem = $fileSystem; - $this->directory = $directory; - $this->expressionLanguage = new ExpressionLanguage(); } + #[\Override] function processData(DataItemInterface $item, ExecutionContext $context): ItemInterface { $pattern = $item->getData(); $files = []; $directory = $this->directory; - if (strpos($this->directory, "@") === 0) { + if (str_starts_with($this->directory, "@")) { $directory = ltrim($this->directory, '@'); $directory = $this->expressionLanguage->evaluate($directory, ['context' => $context->getParameters()]); } foreach ($this->fileSystem->listContents($directory) as $file) { - if (preg_match($pattern, $file) !== 0) { + if (preg_match($pattern, (string) $file) !== 0) { $files[] = new ExternalFileItem($directory . "/" . $file, $this->fileSystem); } } diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/Extract/JsonExtractOperation.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/Extract/JsonExtractOperation.php index 5bfb6bd..10912d9 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/Extract/JsonExtractOperation.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/Extract/JsonExtractOperation.php @@ -14,16 +14,11 @@ class JsonExtractOperation extends AbstractChainOperation implements DataChainOperationInterface { - protected string $fileKey; - - protected bool $scoped; - - public function __construct(string $fileKey, bool $scoped) + public function __construct(protected string $fileKey, protected bool $scoped) { - $this->fileKey = $fileKey; - $this->scoped = $scoped; } + #[\Override] public function processData(DataItemInterface $item, ExecutionContext $context): ItemInterface { $filename = $item->getData(); diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/FailSafeOperation.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/FailSafeOperation.php index d622892..4ac64a6 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/FailSafeOperation.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/FailSafeOperation.php @@ -22,6 +22,7 @@ public function __construct( protected readonly int $nbAttempts, ){} + #[\Override] public function process(ItemInterface $item, ExecutionContext $context) { if ($item instanceof StopItem) { diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/Grouping/SimpleGroupingOperation.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/Grouping/SimpleGroupingOperation.php index 2fab9e7..ad4068d 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/Grouping/SimpleGroupingOperation.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/Grouping/SimpleGroupingOperation.php @@ -52,6 +52,7 @@ public function __construct(array $groupKey, array $groupIdentifierKey = []) /** * @inheritdoc */ + #[\Override] public function processData(DataItemInterface $item, ExecutionContext $context): ChainBreakItem { $groupingValue = AssociativeArray::getFromKey($item->getData(), $this->groupKey); diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/Loader/FileWriterOperation.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/Loader/FileWriterOperation.php index e4a463a..44475e3 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/Loader/FileWriterOperation.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/Loader/FileWriterOperation.php @@ -26,17 +26,15 @@ class FileWriterOperation extends AbstractChainOperation implements DataChainOpe /** @var FileWriterInterface */ protected $writer; - protected string $fileName; - - public function __construct(FileWriterInterface $writer, string $fileName) + public function __construct(FileWriterInterface $writer, protected string $fileName) { $this->writer = $writer; - $this->fileName = $fileName; } /** * @inheritdoc */ + #[\Override] public function processData(DataItemInterface $item, ExecutionContext $context): DataItemInterface { $this->writer->write($item->getData()); diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/SplittedChainOperationTrait.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/SplittedChainOperationTrait.php index a2e5c28..68757c0 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/SplittedChainOperationTrait.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/SplittedChainOperationTrait.php @@ -17,7 +17,7 @@ protected function onSplittedChainOperationConstruct(array $chainProcessors): vo $lastObservedState = &$this->lastObservedState; foreach ($chainProcessors as $subChainPart => $chainProcessor) { if ($chainProcessor instanceof ChainProcessor) { - $observer = $chainProcessor->initObserver(function (array $operationStates) use (&$lastObservedState, $subChainPart) { + $observer = $chainProcessor->initObserver(function (array $operationStates) use (&$lastObservedState, $subChainPart): void { $lastObservedState[$subChainPart] = $operationStates; }); diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/CallbackTransformerOperation.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/CallbackTransformerOperation.php index b188ad1..c81edc2 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/CallbackTransformerOperation.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/CallbackTransformerOperation.php @@ -19,21 +19,19 @@ */ class CallbackTransformerOperation extends AbstractChainOperation implements DataChainOperationInterface { - protected $callback; - /** * CallbackTransformerOperation constructor. * * @param $callback */ - public function __construct($callback) + public function __construct(protected $callback) { - $this->callback = $callback; } /** * @inheritdoc */ + #[\Override] public function processData(DataItemInterface $item, ExecutionContext $context): ItemInterface { $method = $this->callback; diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/FilterDataOperation.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/FilterDataOperation.php index 850494c..2fd6b59 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/FilterDataOperation.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/FilterDataOperation.php @@ -12,20 +12,12 @@ class FilterDataOperation extends AbstractChainOperation implements DataChainOperationInterface { - protected RuleApplier $ruleApplier; - - protected array $rule; - - protected bool $negate; - - public function __construct(RuleApplier $ruleApplier, array $rule, bool $negate) + public function __construct(protected RuleApplier $ruleApplier, protected array $rule, protected bool $negate) { - $this->ruleApplier = $ruleApplier; - $this->rule = $rule; - $this->negate = $negate; } + #[\Override] public function processData(DataItemInterface $item, ExecutionContext $context): ItemInterface { $data = $item->getData(); diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/LogOperation.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/LogOperation.php index 06c10ac..f74fd2a 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/LogOperation.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/LogOperation.php @@ -23,11 +23,12 @@ public function __construct( $this->expressionLanguage = new ExpressionLanguage(); } + #[\Override] public function processData(DataItemInterface $item, ExecutionContext $context): ItemInterface { $data = new AssociativeArray($item->getData()); $message = $this->message; - if (strpos($message, "@") === 0) { + if (str_starts_with($message, "@")) { $message = ltrim($message, "@"); $message = $this->expressionLanguage->evaluate($message, ['data' => $item->getData(), 'context' => $context->getParameters()]); } @@ -37,32 +38,17 @@ public function processData(DataItemInterface $item, ExecutionContext $context): $logContext[$key] = $data->get($valueKey); } - switch ($this->level) { - case 'debug': - $context->getLogger()->debug($message, $logContext); - break; - case 'info': - $context->getLogger()->info($message, $logContext); - break; - case 'notice': - $context->getLogger()->notice($message, $logContext); - break; - case 'warning': - $context->getLogger()->warning($message, $logContext); - break; - case 'error': - $context->getLogger()->error($message, $logContext); - break; - case 'critical': - $context->getLogger()->critical($message, $logContext); - break; - case 'alert': - $context->getLogger()->alert($message, $logContext); - break; - case 'emergency': - $context->getLogger()->emergency($message, $logContext); - break; - } + match ($this->level) { + 'debug' => $context->getLogger()->debug($message, $logContext), + 'info' => $context->getLogger()->info($message, $logContext), + 'notice' => $context->getLogger()->notice($message, $logContext), + 'warning' => $context->getLogger()->warning($message, $logContext), + 'error' => $context->getLogger()->error($message, $logContext), + 'critical' => $context->getLogger()->critical($message, $logContext), + 'alert' => $context->getLogger()->alert($message, $logContext), + 'emergency' => $context->getLogger()->emergency($message, $logContext), + default => $item, + }; return $item; } diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/RuleTransformOperation.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/RuleTransformOperation.php index f74915e..8a2f35b 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/RuleTransformOperation.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/RuleTransformOperation.php @@ -27,22 +27,11 @@ class RuleTransformOperation extends AbstractChainOperation implements DataChain /** @var string[] */ protected array $parsedColumns = []; - /** @var RuleApplier */ - protected RuleApplier $ruleApplier; - - /** @var array */ - protected array $rules; - - /** @var boolean */ - protected bool $add; - - public function __construct(RuleApplier $ruleApplier, array $rules, bool $add) + public function __construct(protected RuleApplier $ruleApplier, protected array $rules, protected bool $add) { - $this->ruleApplier = $ruleApplier; - $this->rules = $rules; - $this->add = $add; } + #[\Override] public function processData(DataItemInterface $item, ExecutionContext $context): DataItemInterface { $data = $item->getData(); diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/SimpleHttpOperation.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/SimpleHttpOperation.php index 7559522..619fd06 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/SimpleHttpOperation.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/SimpleHttpOperation.php @@ -17,38 +17,21 @@ class SimpleHttpOperation extends AbstractChainOperation implements DataChainOperationInterface { - private HttpClientInterface $client; - - private string $method = "GET"; - private string $url; - - private bool $responseIsJson; - - private ?string $optionsKey; - - protected ?string $responseKey; - - private ExpressionLanguage $expressionLanguage; + private readonly ExpressionLanguage $expressionLanguage; public function __construct( - HttpClientInterface $client, - string $method, - string $url, - bool $responseIsJson, - ?string $optionsKey, - ?string $responseKey + private readonly HttpClientInterface $client, + private readonly string $method, + private readonly string $url, + private readonly bool $responseIsJson, + private readonly ?string $optionsKey, + protected ?string $responseKey ) { - $this->client = $client; - $this->method = $method; - $this->url = $url; - $this->responseIsJson = $responseIsJson; - $this->optionsKey = $optionsKey; - $this->responseKey = $responseKey; - $this->expressionLanguage = new ExpressionLanguage(); } + #[\Override] public function processData(DataItemInterface $item, ExecutionContext $context): ItemInterface { $data = $item->getData(); @@ -59,7 +42,7 @@ public function processData(DataItemInterface $item, ExecutionContext $context): } $url = $this->url; - if (strpos($url, "@") === 0) { + if (str_starts_with($url, "@")) { $url = ltrim($url, '@'); $url = $this->expressionLanguage->evaluate($url, ['data' => $data]); } diff --git a/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/SplitItemOperation.php b/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/SplitItemOperation.php index 5194a15..f01dbe7 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/SplitItemOperation.php +++ b/src/Oliverde8/Component/PhpEtl/ChainOperation/Transformer/SplitItemOperation.php @@ -15,28 +15,14 @@ class SplitItemOperation extends AbstractChainOperation implements DataChainOperationInterface { - protected bool $singleElement; - - protected bool $keepKeys; - - protected array $keys; - - protected ?string $keyName; - - protected array $duplicateKeys; - - public function __construct(bool $singleElement, array $keys, bool $keepKeys, string $keyName = null, array $duplicatekeys = []) + public function __construct(protected bool $singleElement, protected array $keys, protected bool $keepKeys, protected ?string $keyName = null, protected array $duplicateKeys = []) { - $this->singleElement = $singleElement; - $this->keepKeys = $keepKeys; - $this->keys = $keys; - $this->keyName = $keyName; - $this->duplicateKeys = $duplicatekeys; } /** * @throws ChainOperationException */ + #[\Override] public function processData(DataItemInterface $item, ExecutionContext $context): ItemInterface { if ($this->singleElement) { diff --git a/src/Oliverde8/Component/PhpEtl/ChainProcessor.php b/src/Oliverde8/Component/PhpEtl/ChainProcessor.php index 17c305e..37701a2 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainProcessor.php +++ b/src/Oliverde8/Component/PhpEtl/ChainProcessor.php @@ -21,7 +21,7 @@ final class ChainProcessor extends LoggerContext implements ChainProcessorInterface { - const KEY_LOGGER_ETL_IDENTIFIER = 'etl.identifier'; + const string KEY_LOGGER_ETL_IDENTIFIER = 'etl.identifier'; /** @var ChainOperationInterface[] */ protected readonly array $chainLinks; @@ -53,6 +53,7 @@ public function __construct( } + #[\Override] public function process(\Iterator|ItemInterface $item, array $parameters, ?callable $observerCallback = null, $withStop = true): void { $context = $this->contextFactory->get($parameters); @@ -76,6 +77,7 @@ public function process(\Iterator|ItemInterface $item, array $parameters, ?calla } } + #[\Override] public function processGenerator( \Iterator|ItemInterface $item, ExecutionContext $context, @@ -181,7 +183,7 @@ protected function getItemsFromGroupItem(GroupedItem $item): \Generator } } - protected function handleAsyncItems(int $maxItems = null): \Generator + protected function handleAsyncItems(?int $maxItems = null): \Generator { if ($maxItems === null) { $maxItems = $this->maxAsynchronousItems; @@ -258,7 +260,7 @@ public function initObserver(?callable $observerCallback = null): ChainObserver } if (!$observerCallback) { - $observerCallback = function (){}; + $observerCallback = function (): void{}; } $this->chainObserver = new ChainObserver($observerCallback); $this->chainObserver->init($this->chainLinks, $this->chainLinkNames); @@ -266,11 +268,13 @@ public function initObserver(?callable $observerCallback = null): ChainObserver return $this->chainObserver; } + #[\Override] public function getChainLinkNames(): array { return $this->chainLinkNames; } + #[\Override] public function getChainLinks(): array { return $this->chainLinks; diff --git a/src/Oliverde8/Component/PhpEtl/ChainWorkDirManager.php b/src/Oliverde8/Component/PhpEtl/ChainWorkDirManager.php index cf3a627..4425ad6 100644 --- a/src/Oliverde8/Component/PhpEtl/ChainWorkDirManager.php +++ b/src/Oliverde8/Component/PhpEtl/ChainWorkDirManager.php @@ -8,13 +8,10 @@ class ChainWorkDirManager { - private string $baseDir; + private readonly LocalFileSystem $fileSystem; - private LocalFileSystem $fileSystem; - - public function __construct(string $baseDir) + public function __construct(private readonly string $baseDir) { - $this->baseDir = $baseDir; $this->fileSystem = new LocalFileSystem('/'); } diff --git a/src/Oliverde8/Component/PhpEtl/Exception/ChainBuilderValidationException.php b/src/Oliverde8/Component/PhpEtl/Exception/ChainBuilderValidationException.php index 598d664..235282b 100644 --- a/src/Oliverde8/Component/PhpEtl/Exception/ChainBuilderValidationException.php +++ b/src/Oliverde8/Component/PhpEtl/Exception/ChainBuilderValidationException.php @@ -24,7 +24,7 @@ class ChainBuilderValidationException extends \Exception * @param int $code * @param Throwable|null $previous */ - public function __construct(string $operation, array $violations, int $code = 0, Throwable $previous = null) + public function __construct(string $operation, array $violations, int $code = 0, ?Throwable $previous = null) { $msg = "There was an error building the operation '$operation' : "; foreach ($violations as $violation) { diff --git a/src/Oliverde8/Component/PhpEtl/Exception/ChainOperationException.php b/src/Oliverde8/Component/PhpEtl/Exception/ChainOperationException.php index 5e44b15..83c52b6 100644 --- a/src/Oliverde8/Component/PhpEtl/Exception/ChainOperationException.php +++ b/src/Oliverde8/Component/PhpEtl/Exception/ChainOperationException.php @@ -15,16 +15,11 @@ */ class ChainOperationException extends \Exception { - /** @var string */ - protected string $chainOperationName; - /** * ChainOperationException constructor. */ - public function __construct(string $message = "", int $code = 0, \Exception $previous = null, string $chainOperationName = '') + public function __construct(string $message = "", int $code = 0, ?\Exception $previous = null, protected string $chainOperationName = '') { - $this->chainOperationName = $chainOperationName; - parent::__construct($message, $code, $previous); } diff --git a/src/Oliverde8/Component/PhpEtl/ExecutionContextFactory.php b/src/Oliverde8/Component/PhpEtl/ExecutionContextFactory.php index 924731c..8a77ed5 100644 --- a/src/Oliverde8/Component/PhpEtl/ExecutionContextFactory.php +++ b/src/Oliverde8/Component/PhpEtl/ExecutionContextFactory.php @@ -7,6 +7,7 @@ class ExecutionContextFactory implements ExecutionContextFactoryInterface { + #[\Override] public function get(array $parameters): ExecutionContext { return new ExecutionContext($parameters, new LocalFileSystem()); diff --git a/src/Oliverde8/Component/PhpEtl/Extract/File/Csv.php b/src/Oliverde8/Component/PhpEtl/Extract/File/Csv.php index 4abc5a4..43feca6 100644 --- a/src/Oliverde8/Component/PhpEtl/Extract/File/Csv.php +++ b/src/Oliverde8/Component/PhpEtl/Extract/File/Csv.php @@ -83,6 +83,7 @@ public function setHeaders(array $headers): void * @return mixed Can return any type. * @since 5.0.0 */ + #[\Override] public function current(): mixed { $this->init(); @@ -97,6 +98,7 @@ public function current(): mixed * @return void Any returned value is ignored. * @since 5.0.0 */ + #[\Override] public function next(): void { $this->init(); @@ -119,6 +121,7 @@ public function next(): void * @return mixed scalar on success, or null on failure. * @since 5.0.0 */ + #[\Override] public function key(): mixed { $this->init(); @@ -134,6 +137,7 @@ public function key(): mixed * Returns true on success or false on failure. * @since 5.0.0 */ + #[\Override] public function valid(): bool { $this->init(); @@ -148,6 +152,7 @@ public function valid(): bool * @return void Any returned value is ignored. * @since 5.0.0 */ + #[\Override] public function rewind(): void { if (!is_null($this->file)) { diff --git a/src/Oliverde8/Component/PhpEtl/Factory/LocalFileSystemFactory.php b/src/Oliverde8/Component/PhpEtl/Factory/LocalFileSystemFactory.php index 9a2e57f..9acdf88 100644 --- a/src/Oliverde8/Component/PhpEtl/Factory/LocalFileSystemFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Factory/LocalFileSystemFactory.php @@ -10,16 +10,14 @@ class LocalFileSystemFactory implements FileSystemFactoryInterface { - private ChainWorkDirManager $chainWorkDirManager; - /** @var FileSystemInterface[] */ private array $fileSystems; - public function __construct(ChainWorkDirManager $chainWorkDirManager) + public function __construct(private readonly ChainWorkDirManager $chainWorkDirManager) { - $this->chainWorkDirManager = $chainWorkDirManager; } + #[\Override] public function get(ExecutionInterface $execution): FileSystemInterface { if (!isset($this->fileSystems[$execution->getId()])) { diff --git a/src/Oliverde8/Component/PhpEtl/Factory/NullLoggerFactory.php b/src/Oliverde8/Component/PhpEtl/Factory/NullLoggerFactory.php index 2a7efa6..d21defe 100644 --- a/src/Oliverde8/Component/PhpEtl/Factory/NullLoggerFactory.php +++ b/src/Oliverde8/Component/PhpEtl/Factory/NullLoggerFactory.php @@ -9,6 +9,7 @@ class NullLoggerFactory implements LoggerFactoryInterface { + #[\Override] public function get(ExecutionInterface $execution): LoggerInterface { return new NullLogger(); diff --git a/src/Oliverde8/Component/PhpEtl/Item/AsyncHttpClientResponseItem.php b/src/Oliverde8/Component/PhpEtl/Item/AsyncHttpClientResponseItem.php index f90de31..b1b4efa 100644 --- a/src/Oliverde8/Component/PhpEtl/Item/AsyncHttpClientResponseItem.php +++ b/src/Oliverde8/Component/PhpEtl/Item/AsyncHttpClientResponseItem.php @@ -10,16 +10,6 @@ class AsyncHttpClientResponseItem implements AsyncItemInterface { - private HttpClientInterface $client; - - private ResponseInterface $response; - - private bool $responseIsJson; - - private ?string $responseKey; - - private array $baseData; - private bool $isRunning = true; /** @@ -28,21 +18,12 @@ class AsyncHttpClientResponseItem implements AsyncItemInterface * @param string|null $responseKey * @param array $baseData */ - public function __construct( - HttpClientInterface $client, - ResponseInterface $response, - bool $responseIsJson, - ?string $responseKey, - array $baseData - ) { - $this->client = $client; - $this->response = $response; - $this->responseIsJson = $responseIsJson; - $this->responseKey = $responseKey; - $this->baseData = $baseData; + public function __construct(private readonly HttpClientInterface $client, private readonly ResponseInterface $response, private readonly bool $responseIsJson, private readonly ?string $responseKey, private readonly array $baseData) + { } + #[\Override] public function isRunning(): bool { try { @@ -51,13 +32,14 @@ public function isRunning(): bool return false; } } - } catch (TimeoutException $exception) { + } catch (TimeoutException) { // This is normal, we have used a very low stream timeout because we wish to continue processing // other items while this item is being downloaded. return true; } } + #[\Override] public function getItem(): ItemInterface { $responseData = [ diff --git a/src/Oliverde8/Component/PhpEtl/Item/DataItem.php b/src/Oliverde8/Component/PhpEtl/Item/DataItem.php index ba38bc7..07a8369 100644 --- a/src/Oliverde8/Component/PhpEtl/Item/DataItem.php +++ b/src/Oliverde8/Component/PhpEtl/Item/DataItem.php @@ -13,21 +13,14 @@ */ class DataItem implements DataItemInterface { - /** - * @var mixed - */ - protected $data; - /** * DataItem constructor. - * - * @param mixed $data */ - public function __construct($data) + public function __construct(protected mixed $data) { - $this->data = $data; } + #[\Override] public function getData() { return $this->data; diff --git a/src/Oliverde8/Component/PhpEtl/Item/ExternalFileItem.php b/src/Oliverde8/Component/PhpEtl/Item/ExternalFileItem.php index 95e7d0b..56006d1 100644 --- a/src/Oliverde8/Component/PhpEtl/Item/ExternalFileItem.php +++ b/src/Oliverde8/Component/PhpEtl/Item/ExternalFileItem.php @@ -12,16 +12,10 @@ class ExternalFileItem implements ItemInterface const STATE_PROCESSED = "processed"; - protected string $filePath; - - protected FileSystemInterface $fileSystem; - protected string $state; - public function __construct(string $filePath, FileSystemInterface $fileSystem) + public function __construct(protected string $filePath, protected FileSystemInterface $fileSystem) { - $this->fileSystem = $fileSystem; - $this->filePath = $filePath; $this->state = self::STATE_NEW; } diff --git a/src/Oliverde8/Component/PhpEtl/Item/FileExtractedItem.php b/src/Oliverde8/Component/PhpEtl/Item/FileExtractedItem.php index 59c5866..6cc9b19 100644 --- a/src/Oliverde8/Component/PhpEtl/Item/FileExtractedItem.php +++ b/src/Oliverde8/Component/PhpEtl/Item/FileExtractedItem.php @@ -4,11 +4,8 @@ class FileExtractedItem extends FileItem { - private string $filePath; - - public function __construct(string $filePath) + public function __construct(private readonly string $filePath) { - $this->filePath = $filePath; } public function getFilePath(): string diff --git a/src/Oliverde8/Component/PhpEtl/Item/FileLoadedItem.php b/src/Oliverde8/Component/PhpEtl/Item/FileLoadedItem.php index 5d6cd35..9716886 100644 --- a/src/Oliverde8/Component/PhpEtl/Item/FileLoadedItem.php +++ b/src/Oliverde8/Component/PhpEtl/Item/FileLoadedItem.php @@ -4,11 +4,8 @@ class FileLoadedItem extends FileItem { - private string $filePath; - - public function __construct(string $filePath) + public function __construct(private readonly string $filePath) { - $this->filePath = $filePath; } public function getFilePath(): string diff --git a/src/Oliverde8/Component/PhpEtl/Item/GroupedItem.php b/src/Oliverde8/Component/PhpEtl/Item/GroupedItem.php index 0d62981..e329e82 100644 --- a/src/Oliverde8/Component/PhpEtl/Item/GroupedItem.php +++ b/src/Oliverde8/Component/PhpEtl/Item/GroupedItem.php @@ -14,16 +14,14 @@ class GroupedItem implements GroupedItemInterface { - protected \Iterator $iterator; - - public function __construct(\Iterator $iterator) + public function __construct(protected \Iterator $iterator) { - $this->iterator = $iterator; } /** * @inheritdoc */ + #[\Override] public function getIterator(): \Iterator { return $this->iterator; diff --git a/src/Oliverde8/Component/PhpEtl/Item/MixItem.php b/src/Oliverde8/Component/PhpEtl/Item/MixItem.php index b46ca63..9767989 100644 --- a/src/Oliverde8/Component/PhpEtl/Item/MixItem.php +++ b/src/Oliverde8/Component/PhpEtl/Item/MixItem.php @@ -4,11 +4,8 @@ class MixItem implements ItemInterface { - private array $items; - - public function __construct(array $items) + public function __construct(private readonly array $items) { - $this->items = $items; } public function getItems(): array diff --git a/src/Oliverde8/Component/PhpEtl/Load/File/Csv.php b/src/Oliverde8/Component/PhpEtl/Load/File/Csv.php index 97ad3c6..3972ff4 100644 --- a/src/Oliverde8/Component/PhpEtl/Load/File/Csv.php +++ b/src/Oliverde8/Component/PhpEtl/Load/File/Csv.php @@ -13,21 +13,17 @@ */ class Csv extends AbstractCsvFile implements FileWriterInterface { - /** @var bool */ - protected $hasHeader; - /** * Writer constructor. * * @param $filePath - * @param bool $hasHeaders + * @param bool $hasHeader * @param string $delimiter * @param string $enclosure * @param string $escape */ - public function __construct($filePath, $hasHeaders = true, $delimiter = ';', $enclosure = '"', $escape = '\\') + public function __construct($filePath, protected $hasHeader = true, $delimiter = ';', $enclosure = '"', $escape = '\\') { - $this->hasHeader = $hasHeaders; parent::__construct($filePath, $delimiter, $enclosure, $escape); } @@ -46,6 +42,7 @@ protected function init($rowData) } } + #[\Override] public function getResource() { $this->init([]); @@ -58,6 +55,7 @@ public function getResource() * * @param array $rowData data to wrinte in a line of the csv. */ + #[\Override] public function write($rowData) { $this->init($rowData); diff --git a/src/Oliverde8/Component/PhpEtl/Load/File/Json.php b/src/Oliverde8/Component/PhpEtl/Load/File/Json.php index 1bf1c5b..e39b8a3 100644 --- a/src/Oliverde8/Component/PhpEtl/Load/File/Json.php +++ b/src/Oliverde8/Component/PhpEtl/Load/File/Json.php @@ -4,14 +4,11 @@ class Json implements FileWriterInterface { - protected string $filePath; - /** @var resource File pointer */ protected $file = null; - public function __construct(string $filePath) + public function __construct(protected string $filePath) { - $this->filePath = $filePath; } protected function init() @@ -21,12 +18,14 @@ protected function init() } } + #[\Override] public function write($rowData) { $this->init(); fputs($this->file, json_encode($rowData) . "\n"); } + #[\Override] public function getResource() { $this->init(); diff --git a/src/Oliverde8/Component/PhpEtl/Model/ExecutionContext.php b/src/Oliverde8/Component/PhpEtl/Model/ExecutionContext.php index 523d6da..26fda79 100644 --- a/src/Oliverde8/Component/PhpEtl/Model/ExecutionContext.php +++ b/src/Oliverde8/Component/PhpEtl/Model/ExecutionContext.php @@ -9,18 +9,12 @@ class ExecutionContext extends LoggerContext { - protected array $parameters; - - protected FileSystemInterface $fileSystem; - /** * @param array $parameters * @param FileSystemInterface $fileSystem */ - public function __construct(array $parameters, FileSystemInterface $fileSystem) + public function __construct(protected array $parameters, protected FileSystemInterface $fileSystem) { - $this->parameters = $parameters; - $this->fileSystem = $fileSystem; } diff --git a/src/Oliverde8/Component/PhpEtl/Model/File/AbstractCsvFile.php b/src/Oliverde8/Component/PhpEtl/Model/File/AbstractCsvFile.php index 6cecae8..77800f1 100644 --- a/src/Oliverde8/Component/PhpEtl/Model/File/AbstractCsvFile.php +++ b/src/Oliverde8/Component/PhpEtl/Model/File/AbstractCsvFile.php @@ -11,9 +11,6 @@ */ class AbstractCsvFile { - /** @var String */ - protected $filePath; - /** @var string */ protected $delimiter; @@ -34,9 +31,8 @@ class AbstractCsvFile * @param string $enclosure Enclosure to use for the csv file. * @param string $escape Escape to use for the csv file. */ - public function __construct($filePath, string $delimiter = ';', string $enclosure = '"', string $escape = '\\') + public function __construct(protected $filePath, string $delimiter = ';', string $enclosure = '"', string $escape = '\\') { - $this->filePath = $filePath; $this->delimiter = $delimiter; $this->enclosure = $enclosure; $this->escape = $escape; diff --git a/src/Oliverde8/Component/PhpEtl/Model/File/FlySystemFileSystem.php b/src/Oliverde8/Component/PhpEtl/Model/File/FlySystemFileSystem.php index 4686ddf..0728a7b 100644 --- a/src/Oliverde8/Component/PhpEtl/Model/File/FlySystemFileSystem.php +++ b/src/Oliverde8/Component/PhpEtl/Model/File/FlySystemFileSystem.php @@ -17,62 +17,74 @@ public function __construct(Filesystem $filesystem) $this->filesystem = $filesystem; } + #[\Override] public function getRootPath(): string { return "/"; } + #[\Override] public function fileExists(string $path): bool { return $this->filesystem->fileExists($path); } + #[\Override] public function write(string $path, string $contents, array $config = []): void { $this->filesystem->write($path, $contents, $config); } + #[\Override] public function writeStream(string $path, $contents, array $config = []): void { $this->filesystem->writeStream($path, $contents, $config); } + #[\Override] public function read(string $path): string { return $this->filesystem->read($path); } + #[\Override] public function readStream(string $path) { return $this->filesystem->readStream($path); } + #[\Override] public function delete(string $path): void { $this->filesystem->delete($path); } + #[\Override] public function deleteDirectory(string $path): void { $this->filesystem->deleteDirectory($path); } + #[\Override] public function createDirectory(string $path, array $config = []): void { $this->filesystem->createDirectory($path, $config); } + #[\Override] public function listContents(string $path): array { $listing = $this->filesystem->listContents($path); return $listing->toArray(); } + #[\Override] public function move(string $source, string $destination, array $config = []) { $this->filesystem->move($source, $destination, $config); } + #[\Override] public function copy(string $source, string $destination, array $config = []) { $this->filesystem->copy($source, $destination, $config); diff --git a/src/Oliverde8/Component/PhpEtl/Model/File/LocalFileSystem.php b/src/Oliverde8/Component/PhpEtl/Model/File/LocalFileSystem.php index ee408e0..a0e5d72 100644 --- a/src/Oliverde8/Component/PhpEtl/Model/File/LocalFileSystem.php +++ b/src/Oliverde8/Component/PhpEtl/Model/File/LocalFileSystem.php @@ -28,62 +28,74 @@ public function __construct($rootPath = null) /** * @return string */ + #[\Override] public function getRootPath(): string { return $this->rootPath; } + #[\Override] public function fileExists(string $path): bool { return $this->filesystem->exists($this->rootPath . "/" . $path); } + #[\Override] public function write(string $path, string $contents, array $config = []): void { $this->filesystem->dumpFile($this->rootPath . "/" . $path, $contents); } + #[\Override] public function writeStream(string $path, $contents, array $config = []): void { stream_copy_to_stream($contents, fopen($this->rootPath . "/" . $path, 'w+')); } + #[\Override] public function read(string $path): string { return file_get_contents($this->rootPath . "/" . $path); } + #[\Override] public function readStream(string $path) { return fopen($this->rootPath . "/" . $path, 'r'); } + #[\Override] public function delete(string $path): void { $this->filesystem->remove($this->rootPath . "/" . $path); } + #[\Override] public function deleteDirectory(string $path): void { $this->filesystem->remove($this->rootPath . "/" . $path); } + #[\Override] public function createDirectory(string $path, array $config = []): void { $this->filesystem->mkdir($this->rootPath . "/" . $path); } + #[\Override] public function listContents(string $path): array { $files = scandir($this->rootPath . "/" .$path); return $files ?: []; } + #[\Override] public function move(string $source, string $destination, array $config = []) { $this->filesystem->rename($this->rootPath . "/" . $source, $this->rootPath . "/" . $destination); } + #[\Override] public function copy(string $source, string $destination, array $config = []) { $this->filesystem->copy($this->rootPath . "/" . $source, $this->rootPath . "/" . $destination); diff --git a/src/Oliverde8/Component/PhpEtl/Model/File/ProxySubFileSystem.php b/src/Oliverde8/Component/PhpEtl/Model/File/ProxySubFileSystem.php index 31b97c3..63e9707 100644 --- a/src/Oliverde8/Component/PhpEtl/Model/File/ProxySubFileSystem.php +++ b/src/Oliverde8/Component/PhpEtl/Model/File/ProxySubFileSystem.php @@ -6,73 +6,82 @@ class ProxySubFileSystem implements FileSystemInterface { protected $subDir; - protected FileSystemInterface $fileSystem; - /** * @param $subDir * @param FileSystemInterface $fileSystem */ - public function __construct($subDir, FileSystemInterface $fileSystem) + public function __construct($subDir, protected FileSystemInterface $fileSystem) { - $this->subDir = "/" . trim($subDir, "/") . "/"; - $this->fileSystem = $fileSystem; + $this->subDir = "/" . trim((string) $subDir, "/") . "/"; } + #[\Override] public function getRootPath(): string { return $this->fileSystem->getRootPath() . $this->subDir; } + #[\Override] public function fileExists(string $path): bool { return $this->fileSystem->fileExists($this->subDir . $path); } + #[\Override] public function write(string $path, string $contents, array $config = []): void { $this->fileSystem->write($this->subDir . $path, $contents, $config); } + #[\Override] public function writeStream(string $path, $contents, array $config = []): void { $this->fileSystem->writeStream($this->subDir . $path, $contents, $config); } + #[\Override] public function read(string $path): string { return $this->fileSystem->read($this->subDir . $path); } + #[\Override] public function readStream(string $path) { return $this->fileSystem->readStream($this->subDir . $path); } + #[\Override] public function delete(string $path): void { $this->fileSystem->delete($this->subDir . $path); } + #[\Override] public function deleteDirectory(string $path): void { $this->fileSystem->deleteDirectory($this->subDir . $path); } + #[\Override] public function createDirectory(string $path, array $config = []): void { $this->fileSystem->createDirectory($this->subDir . $path, $config); } + #[\Override] public function listContents(string $path): array { return $this->fileSystem->listContents($this->subDir . $path); } + #[\Override] public function move(string $source, string $destination, array $config = []) { $this->fileSystem->move($this->subDir . $source, $this->subDir . $destination, $config); } + #[\Override] public function copy(string $source, string $destination, array $config = []) { $this->fileSystem->copy($this->subDir . $source, $this->subDir . $destination, $config); diff --git a/src/Oliverde8/Component/PhpEtl/Model/PerExecutionExecutionContext.php b/src/Oliverde8/Component/PhpEtl/Model/PerExecutionExecutionContext.php index d617f6f..76958b7 100644 --- a/src/Oliverde8/Component/PhpEtl/Model/PerExecutionExecutionContext.php +++ b/src/Oliverde8/Component/PhpEtl/Model/PerExecutionExecutionContext.php @@ -9,15 +9,13 @@ class PerExecutionExecutionContext extends ExecutionContext { - protected string $workDir; - - public function __construct(array $parameters, FileSystemInterface $fileSystem, LoggerInterface $logger, string $logPath) + public function __construct(array $parameters, FileSystemInterface $fileSystem, LoggerInterface $logger, protected string $workDir) { parent::__construct($parameters, $fileSystem); $this->logger = $logger; - $this->workDir = $logPath; } + #[\Override] protected function finalise(): void { if (class_exists("Monolog\Logger") && $this->logger instanceof \Monolog\Logger) { diff --git a/src/Oliverde8/Component/PhpEtl/Model/PockExecution.php b/src/Oliverde8/Component/PhpEtl/Model/PockExecution.php index 67a46ba..1cd9950 100644 --- a/src/Oliverde8/Component/PhpEtl/Model/PockExecution.php +++ b/src/Oliverde8/Component/PhpEtl/Model/PockExecution.php @@ -5,22 +5,21 @@ class PockExecution implements ExecutionInterface { - protected \DateTime $createdAt; - protected string $id; - public function __construct(\DateTime $createdAt) + public function __construct(protected \DateTime $createdAt) { - $this->createdAt = $createdAt; - $this->id = (string) rand(1, 100000); + $this->id = (string) random_int(1, 100000); } + #[\Override] public function getId(): string { return $this->id; } + #[\Override] public function GetCreateTime(): \DateTime { return $this->createdAt; diff --git a/src/Oliverde8/Component/PhpEtl/Model/State/OperationState.php b/src/Oliverde8/Component/PhpEtl/Model/State/OperationState.php index 16fe5a5..e13fa11 100644 --- a/src/Oliverde8/Component/PhpEtl/Model/State/OperationState.php +++ b/src/Oliverde8/Component/PhpEtl/Model/State/OperationState.php @@ -12,8 +12,6 @@ class OperationState implements \JsonSerializable { - private readonly string $operationName; - private OperationStateEnum $state = OperationStateEnum::Waiting; private int $itemsProcessed = 0; @@ -29,10 +27,8 @@ class OperationState implements \JsonSerializable private array $subStates = []; - public function __construct(string $operationName, ChainOperationInterface $operation) + public function __construct(private readonly string $operationName, ChainOperationInterface $operation) { - $this->operationName = $operationName; - if ($operation instanceof DetailedObservableOperation) { $this->subStates = $operation->getLastObservedState(); } @@ -126,6 +122,7 @@ protected function returnItem(ChainOperationInterface $operation, ItemInterface } } + #[\Override] public function jsonSerialize(): mixed { $vars = get_object_vars($this); diff --git a/src/Oliverde8/Component/PhpEtl/Output/MermaidStaticOutput.php b/src/Oliverde8/Component/PhpEtl/Output/MermaidStaticOutput.php index e3553af..13b54bc 100644 --- a/src/Oliverde8/Component/PhpEtl/Output/MermaidStaticOutput.php +++ b/src/Oliverde8/Component/PhpEtl/Output/MermaidStaticOutput.php @@ -60,7 +60,7 @@ protected function generateNodes(array $chainProcessors, string $prefix = ""): s /** * @param ChainProcessor[] $chainProcessors */ - protected function generateLinks(array $chainProcessors, string $prefix = "", string $previous = null): string + protected function generateLinks(array $chainProcessors, string $prefix = "", ?string $previous = null): string { $text = ''; $originalPrevious = $previous; diff --git a/src/Oliverde8/Component/PhpEtl/PerExecutionContextFactory.php b/src/Oliverde8/Component/PhpEtl/PerExecutionContextFactory.php index 5cbd346..3f56f63 100644 --- a/src/Oliverde8/Component/PhpEtl/PerExecutionContextFactory.php +++ b/src/Oliverde8/Component/PhpEtl/PerExecutionContextFactory.php @@ -11,23 +11,12 @@ class PerExecutionContextFactory implements ExecutionContextFactoryInterface { - private ChainWorkDirManager $dirManager; - - private FileSystemFactoryInterface $fileSystemFactory; - - private LoggerFactoryInterface $loggerFactory; - - public function __construct( - ChainWorkDirManager $dirManager, - FileSystemFactoryInterface $fileSystemFactory, - LoggerFactoryInterface $loggerFactory - ) { - $this->dirManager = $dirManager; - $this->fileSystemFactory = $fileSystemFactory; - $this->loggerFactory = $loggerFactory; + public function __construct(private readonly ChainWorkDirManager $dirManager, private readonly FileSystemFactoryInterface $fileSystemFactory, private readonly LoggerFactoryInterface $loggerFactory) + { } + #[\Override] public function get(array $parameters): ExecutionContext { $execution = $parameters['etl']['execution'] ?? null; diff --git a/src/Oliverde8/Component/PhpEtl/Tests/ChainBuilderTest.php b/src/Oliverde8/Component/PhpEtl/Tests/ChainBuilderTest.php index 0337260..80df8d6 100644 --- a/src/Oliverde8/Component/PhpEtl/Tests/ChainBuilderTest.php +++ b/src/Oliverde8/Component/PhpEtl/Tests/ChainBuilderTest.php @@ -15,6 +15,7 @@ class ChainBuilderTest extends TestCase private MockObject $mockFactory2; private ChainBuilder $chainBuilder; + #[\Override] protected function setUp(): void { parent::setUp(); // TODO: Change the autogenerated stub @@ -22,18 +23,14 @@ protected function setUp(): void $this->mockFactory1 = $this->getMockBuilder(CsvFileWriterFactory::class)->disableOriginalConstructor()->getMock(); $this->mockFactory1 ->expects($this->any())->method("supports") - ->willReturnCallback(function (string $operation, array $options) { - return $operation == 'op1'; - }); + ->willReturnCallback(fn(string $operation, array $options) => $operation == 'op1'); $this->mockFactory2 = $this->getMockBuilder(CsvFileWriterFactory::class)->disableOriginalConstructor()->getMock(); $this->mockFactory2->expects($this->any())->method("supports") - ->willReturnCallback(function (string $operation, array $options) { - return $operation == 'op2'; - }); + ->willReturnCallback(fn(string $operation, array $options) => $operation == 'op2'); $this->chainBuilder = new ChainBuilder(new ExecutionContextFactory()); - $this->chainBuilder->registerFactory($this->mockFactory1, 'op1'); - $this->chainBuilder->registerFactory($this->mockFactory2, 'op2'); + $this->chainBuilder->registerFactory($this->mockFactory1); + $this->chainBuilder->registerFactory($this->mockFactory2); } diff --git a/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/ChainRepeatOperationTest.php b/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/ChainRepeatOperationTest.php index 0016919..3b2c461 100644 --- a/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/ChainRepeatOperationTest.php +++ b/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/ChainRepeatOperationTest.php @@ -115,4 +115,4 @@ protected function createChain(array $repeatedOperations, array $afterOperations array_unshift($afterOperations, $repeatOperation); return new ChainProcessor($afterOperations, $executionFactory); } -} \ No newline at end of file +} diff --git a/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/FailSafeOperationTest.php b/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/FailSafeOperationTest.php index 6d817df..223a7d6 100644 --- a/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/FailSafeOperationTest.php +++ b/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/FailSafeOperationTest.php @@ -41,7 +41,7 @@ public function testSingleFail() public function testToManyFail() { $callNum = 0; - $failOperation = new CallbackTransformerOperation(function (ItemInterface $item) use (&$callNum) { + $failOperation = new CallbackTransformerOperation(function (ItemInterface $item) use (&$callNum): void { $callNum++; throw new \Exception("Exception at $callNum"); }); diff --git a/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/Loader/FileWriterOperationTest.php b/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/Loader/FileWriterOperationTest.php index 66d2457..6253680 100644 --- a/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/Loader/FileWriterOperationTest.php +++ b/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/Loader/FileWriterOperationTest.php @@ -25,6 +25,7 @@ class FileWriterOperationTest extends TestCase /** @var FileWriterOperation */ protected $writerOperation; + #[\Override] protected function setUp(): void { parent::setUp(); diff --git a/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/Transformer/RuleTransformOperationTest.php b/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/Transformer/RuleTransformOperationTest.php index 86b29d0..a088d96 100644 --- a/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/Transformer/RuleTransformOperationTest.php +++ b/src/Oliverde8/Component/PhpEtl/Tests/ChainOperation/Transformer/RuleTransformOperationTest.php @@ -24,6 +24,7 @@ class RuleTransformOperationTest extends TestCase /** @var MockObject */ protected $context; + #[\Override] protected function setUp(): void { parent::setUp(); diff --git a/src/Oliverde8/Component/PhpEtl/Tests/ChainProcessorTest.php b/src/Oliverde8/Component/PhpEtl/Tests/ChainProcessorTest.php index eda7968..8fd1a6e 100644 --- a/src/Oliverde8/Component/PhpEtl/Tests/ChainProcessorTest.php +++ b/src/Oliverde8/Component/PhpEtl/Tests/ChainProcessorTest.php @@ -222,9 +222,7 @@ public function testReturnOfAsyncItems() return new TestAsyncItem(new DataItem('I am fast'), 1); } }); - $mockEnd = new CallbackTransformerOperation(function (ItemInterface $item) use (&$results) { - return $item; - }); + $mockEnd = new CallbackTransformerOperation(fn(ItemInterface $item) => $item); $chainProcessor = new ChainProcessor(['mock' => $mock, 'mocked_end' => $mockEnd], new ExecutionContextFactory()); foreach ($chainProcessor->processGenerator(new \ArrayIterator([1, 2]), new ExecutionContext([], new LocalFileSystem())) as $item) { @@ -272,12 +270,10 @@ public function testAsyncItemsWithMixItem() { $results = []; - $mock = new CallbackTransformerOperation(function (ItemInterface $item) use (&$callNum) { - return new MixItem([ - new TestAsyncItem(new DataItem('I am slow'), 2), - new TestAsyncItem(new DataItem('I am fast'), 1), - ]); - }); + $mock = new CallbackTransformerOperation(fn(ItemInterface $item) => new MixItem([ + new TestAsyncItem(new DataItem('I am slow'), 2), + new TestAsyncItem(new DataItem('I am fast'), 1), + ])); $mockEnd = new CallbackTransformerOperation(function (ItemInterface $item) use (&$results) { $results[] = $item->getData(); return $item; @@ -296,12 +292,8 @@ public function testAsyncItemsWithMixItem() public function testAsyncDisabledWithSplit() { $results = []; - $mockBranch1 = new CallbackTransformerOperation(function (ItemInterface $item) use (&$callNum) { - return new TestAsyncItem(new DataItem('I am slow'), 2); - }); - $mockBranch2 = new CallbackTransformerOperation(function (ItemInterface $item) use (&$callNum) { - return new TestAsyncItem(new DataItem('I am fast'), 1); - }); + $mockBranch1 = new CallbackTransformerOperation(fn(ItemInterface $item) => new TestAsyncItem(new DataItem('I am slow'), 2)); + $mockBranch2 = new CallbackTransformerOperation(fn(ItemInterface $item) => new TestAsyncItem(new DataItem('I am fast'), 1)); $mockEnd = new CallbackTransformerOperation(function (ItemInterface $item) use (&$results) { $results[] = $item->getData(); return $item; @@ -326,7 +318,7 @@ public function testAsyncDisabledWithSplit() public function testException() { - $mock1 = new CallbackTransformerOperation(function (ItemInterface $item) use (&$count1) { + $mock1 = new CallbackTransformerOperation(function (ItemInterface $item) use (&$count1): void { throw new \Exception('Test exception'); }); diff --git a/src/Oliverde8/Component/PhpEtl/Tests/Item/TestAsyncItem.php b/src/Oliverde8/Component/PhpEtl/Tests/Item/TestAsyncItem.php index 66b602c..3cb7c25 100644 --- a/src/Oliverde8/Component/PhpEtl/Tests/Item/TestAsyncItem.php +++ b/src/Oliverde8/Component/PhpEtl/Tests/Item/TestAsyncItem.php @@ -7,26 +7,21 @@ class TestAsyncItem implements AsyncItemInterface { - private ItemInterface $item; + private readonly int $startTime; - private int $runTime; - - private int $startTime; - - public function __construct(ItemInterface $item, int $runTime) + public function __construct(private readonly ItemInterface $item, private readonly int $runTime) { - $this->item = $item; - $this->runTime = $runTime; - $this->startTime = time(); } + #[\Override] public function isRunning(): bool { return $this->startTime + $this->runTime > time(); } + #[\Override] public function getItem(): ItemInterface { return $this->item; diff --git a/src/Oliverde8/Component/RuleEngine/RuleApplier.php b/src/Oliverde8/Component/RuleEngine/RuleApplier.php index 0e7769a..253ecf4 100644 --- a/src/Oliverde8/Component/RuleEngine/RuleApplier.php +++ b/src/Oliverde8/Component/RuleEngine/RuleApplier.php @@ -18,13 +18,9 @@ */ class RuleApplier { - protected LoggerInterface $logger; - /** @var RuleInterface[] */ protected array $rules; - protected bool $validate; - protected array $currentIdentity; /** @@ -35,11 +31,8 @@ class RuleApplier * @param boolean $validate When validation is active rules are validated and clear messages are displayed * when a rule is not well coded. But performance is worsened. */ - public function __construct(LoggerInterface $logger, array $rules, bool $validate = false) + public function __construct(protected LoggerInterface $logger, array $rules, protected bool $validate = false) { - $this->logger = $logger; - $this->validate = $validate; - foreach ($rules as $rule) { $this->registerRule($rule); } diff --git a/src/Oliverde8/Component/RuleEngine/Rules/AbstractRule.php b/src/Oliverde8/Component/RuleEngine/Rules/AbstractRule.php index ba4630b..b25c6d1 100644 --- a/src/Oliverde8/Component/RuleEngine/Rules/AbstractRule.php +++ b/src/Oliverde8/Component/RuleEngine/Rules/AbstractRule.php @@ -19,16 +19,13 @@ abstract class AbstractRule implements RuleInterface { protected RuleApplier $ruleApplier; - protected LoggerInterface $logger; - /** * AbstractRule constructor. * * @param LoggerInterface $logger Standard logger to log information. */ - public function __construct(LoggerInterface $logger) + public function __construct(protected LoggerInterface $logger) { - $this->logger = $logger; } /** @@ -37,6 +34,7 @@ public function __construct(LoggerInterface $logger) * @param RuleApplier $ruleApplier The rule applier that is using this rule. * @return $this */ + #[\Override] public function setApplier(RuleApplier $ruleApplier): self { $this->ruleApplier = $ruleApplier; diff --git a/src/Oliverde8/Component/RuleEngine/Rules/Constant.php b/src/Oliverde8/Component/RuleEngine/Rules/Constant.php index d759d69..e370306 100644 --- a/src/Oliverde8/Component/RuleEngine/Rules/Constant.php +++ b/src/Oliverde8/Component/RuleEngine/Rules/Constant.php @@ -25,6 +25,7 @@ class Constant extends AbstractRule * * @return string|null */ + #[\Override] public function apply(array $rowData, array &$transformedData, array $options = []) { return $options['value']; @@ -33,6 +34,7 @@ public function apply(array $rowData, array &$transformedData, array $options = /** * @inheritdoc */ + #[\Override] public function validate($options): void { $this->requireOption('value', $options); @@ -43,6 +45,7 @@ public function validate($options): void * * @return string */ + #[\Override] public function getRuleCode(): string { return 'constant'; diff --git a/src/Oliverde8/Component/RuleEngine/Rules/ExpressionLanguage.php b/src/Oliverde8/Component/RuleEngine/Rules/ExpressionLanguage.php index 1f2de5e..3e2eb72 100644 --- a/src/Oliverde8/Component/RuleEngine/Rules/ExpressionLanguage.php +++ b/src/Oliverde8/Component/RuleEngine/Rules/ExpressionLanguage.php @@ -16,6 +16,7 @@ class ExpressionLanguage extends AbstractRule /** * @inheritdoc */ + #[\Override] public function apply(array $rowData, array &$transformedData, array $options = []) { $values = [ @@ -40,6 +41,7 @@ public function apply(array $rowData, array &$transformedData, array $options = * * @return string */ + #[\Override] public function getRuleCode(): string { return 'expression_language'; @@ -49,6 +51,7 @@ public function getRuleCode(): string /** * @inheritdoc */ + #[\Override] public function validate(array $options): void { $this->requireOption('expression', $options); diff --git a/src/Oliverde8/Component/RuleEngine/Rules/Get.php b/src/Oliverde8/Component/RuleEngine/Rules/Get.php index dc490c0..9d3af1b 100644 --- a/src/Oliverde8/Component/RuleEngine/Rules/Get.php +++ b/src/Oliverde8/Component/RuleEngine/Rules/Get.php @@ -18,6 +18,7 @@ class Get extends AbstractRule /** * @inheritdoc */ + #[\Override] public function apply(array $rowData, array &$transformedData, array $options = []) { if (!is_array($options['field'])) { @@ -35,6 +36,7 @@ public function apply(array $rowData, array &$transformedData, array $options = /** * @inheritdoc */ + #[\Override] public function validate(array $options): void { $this->requireOption('field', $options); @@ -43,6 +45,7 @@ public function validate(array $options): void /** * @inheritdoc */ + #[\Override] public function getRuleCode(): string { return 'get'; diff --git a/src/Oliverde8/Component/RuleEngine/Rules/Implode.php b/src/Oliverde8/Component/RuleEngine/Rules/Implode.php index 42c6bf1..30e6a53 100644 --- a/src/Oliverde8/Component/RuleEngine/Rules/Implode.php +++ b/src/Oliverde8/Component/RuleEngine/Rules/Implode.php @@ -16,6 +16,7 @@ class Implode extends AbstractRule /** * @inheritdoc */ + #[\Override] public function apply(array $rowData, array &$transformedData, array $options = []) { $subOptions = $options; @@ -63,6 +64,7 @@ protected function flatten(array $array): \Generator /** * @inheritdoc */ + #[\Override] public function validate(array $options): void { $this->requireOption('values', $options); @@ -72,6 +74,7 @@ public function validate(array $options): void /** * @inheritdoc */ + #[\Override] public function getRuleCode(): string { return 'implode'; diff --git a/src/Oliverde8/Component/RuleEngine/Rules/StrToLower.php b/src/Oliverde8/Component/RuleEngine/Rules/StrToLower.php index 2d79ca0..fc453d0 100644 --- a/src/Oliverde8/Component/RuleEngine/Rules/StrToLower.php +++ b/src/Oliverde8/Component/RuleEngine/Rules/StrToLower.php @@ -16,17 +16,19 @@ class StrToLower extends AbstractRule /** * @inheritdoc */ + #[\Override] public function apply(array $rowData, array &$transformedData, array $options = []): string { $value = $options['value']; unset($options['value']); - return strtolower($this->ruleApplier->apply($rowData, $transformedData, $value, $options)); + return strtolower((string) $this->ruleApplier->apply($rowData, $transformedData, $value, $options)); } /** * @inheritdoc */ + #[\Override] public function validate(array $options): void { $this->requireOption('value', $options); @@ -35,6 +37,7 @@ public function validate(array $options): void /** * @inheritdoc */ + #[\Override] public function getRuleCode(): string { return 'str_lower'; diff --git a/src/Oliverde8/Component/RuleEngine/Rules/StrToUpper.php b/src/Oliverde8/Component/RuleEngine/Rules/StrToUpper.php index dd8f0a8..1d78365 100644 --- a/src/Oliverde8/Component/RuleEngine/Rules/StrToUpper.php +++ b/src/Oliverde8/Component/RuleEngine/Rules/StrToUpper.php @@ -18,17 +18,19 @@ class StrToUpper extends AbstractRule /** * @inheritdoc */ + #[\Override] public function apply(array $rowData, array &$transformedData, array $options = []): string { $value = $options['value']; unset($options['value']); - return strtoupper($this->ruleApplier->apply($rowData, $transformedData, $value, $options)); + return strtoupper((string) $this->ruleApplier->apply($rowData, $transformedData, $value, $options)); } /** * @inheritdoc */ + #[\Override] public function validate(array $options): void { $this->requireOption('value', $options); @@ -37,6 +39,7 @@ public function validate(array $options): void /** * @inheritdoc */ + #[\Override] public function getRuleCode(): string { return 'str_upper'; diff --git a/src/Oliverde8/Component/RuleEngine/Tests/RuleApplierTest.php b/src/Oliverde8/Component/RuleEngine/Tests/RuleApplierTest.php index 02e3697..351f543 100644 --- a/src/Oliverde8/Component/RuleEngine/Tests/RuleApplierTest.php +++ b/src/Oliverde8/Component/RuleEngine/Tests/RuleApplierTest.php @@ -33,6 +33,7 @@ class RuleApplierTest extends TestCase /** * @inheritdoc */ + #[\Override] protected function setUp(): void { parent::setUp(); diff --git a/src/Oliverde8/Component/RuleEngine/Tests/Rules/AbstractRule.php b/src/Oliverde8/Component/RuleEngine/Tests/Rules/AbstractRule.php index 66d9b1e..1e98c78 100644 --- a/src/Oliverde8/Component/RuleEngine/Tests/Rules/AbstractRule.php +++ b/src/Oliverde8/Component/RuleEngine/Tests/Rules/AbstractRule.php @@ -19,6 +19,7 @@ abstract class AbstractRule extends TestCase /** @var RuleInterface */ protected $rule; + #[\Override] protected function setUp(): void { parent::setUp(); diff --git a/src/Oliverde8/Component/RuleEngine/Tests/Rules/ConstantTest.php b/src/Oliverde8/Component/RuleEngine/Tests/Rules/ConstantTest.php index 4aaf8fa..4774240 100644 --- a/src/Oliverde8/Component/RuleEngine/Tests/Rules/ConstantTest.php +++ b/src/Oliverde8/Component/RuleEngine/Tests/Rules/ConstantTest.php @@ -20,6 +20,7 @@ public function testConstants() $this->assertRuleResults(['test' => 'toto 1'], [], ['value' => ['1' => ['toto']]], ['1' => ['toto']]); } + #[\Override] protected function getRule() { return new Constant(new NullLogger()); diff --git a/src/Oliverde8/Component/RuleEngine/Tests/Rules/GetTest.php b/src/Oliverde8/Component/RuleEngine/Tests/Rules/GetTest.php index d9beae7..f4ce75b 100644 --- a/src/Oliverde8/Component/RuleEngine/Tests/Rules/GetTest.php +++ b/src/Oliverde8/Component/RuleEngine/Tests/Rules/GetTest.php @@ -33,6 +33,7 @@ public function testUnfound() /** * @inheritdoc */ + #[\Override] protected function getRule() { return new Get(new NullLogger()); diff --git a/src/Oliverde8/Component/RuleEngine/Tests/Rules/ImplodeTest.php b/src/Oliverde8/Component/RuleEngine/Tests/Rules/ImplodeTest.php index be2f644..1d149de 100644 --- a/src/Oliverde8/Component/RuleEngine/Tests/Rules/ImplodeTest.php +++ b/src/Oliverde8/Component/RuleEngine/Tests/Rules/ImplodeTest.php @@ -52,6 +52,7 @@ public function testFourLevelImplode() /** * @inheritdoc */ + #[\Override] function getRule() { return new Implode(new NullLogger()); diff --git a/src/Oliverde8/Component/RuleEngine/Tests/Rules/StrToLowerTest.php b/src/Oliverde8/Component/RuleEngine/Tests/Rules/StrToLowerTest.php index eb3695e..aa20cb1 100644 --- a/src/Oliverde8/Component/RuleEngine/Tests/Rules/StrToLowerTest.php +++ b/src/Oliverde8/Component/RuleEngine/Tests/Rules/StrToLowerTest.php @@ -25,6 +25,7 @@ public function testStrToLower() /** * @inheritdoc */ + #[\Override] protected function getRule() { return new StrToLower(new NullLogger()); diff --git a/src/Oliverde8/Component/RuleEngine/Tests/Rules/StrToUpperTest.php b/src/Oliverde8/Component/RuleEngine/Tests/Rules/StrToUpperTest.php index 85c98fc..8a1ee8b 100644 --- a/src/Oliverde8/Component/RuleEngine/Tests/Rules/StrToUpperTest.php +++ b/src/Oliverde8/Component/RuleEngine/Tests/Rules/StrToUpperTest.php @@ -25,6 +25,7 @@ public function testStrToUpper() /** * @inheritdoc */ + #[\Override] protected function getRule() { return new StrToUpper(new NullLogger()); diff --git a/src/Oliverde8/Component/RuleEngine/Tests/Rules/TestRuleApplier.php b/src/Oliverde8/Component/RuleEngine/Tests/Rules/TestRuleApplier.php index b28dd59..1805f1d 100644 --- a/src/Oliverde8/Component/RuleEngine/Tests/Rules/TestRuleApplier.php +++ b/src/Oliverde8/Component/RuleEngine/Tests/Rules/TestRuleApplier.php @@ -14,6 +14,7 @@ */ class TestRuleApplier extends RuleApplier { + #[\Override] public function apply($rowData, $transformedData, $rules, $options = [], $identifier = []) { return $rules;